From 0dc6e92cd018aa0ecea5349a14599279e1a2a574 Mon Sep 17 00:00:00 2001 From: Mitch Riedstra Date: Mon, 6 Feb 2017 09:06:37 -0500 Subject: Simplified the Archive library. Added a way to pull the config from the web application --- lib/steam/package.go | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) (limited to 'lib/steam') diff --git a/lib/steam/package.go b/lib/steam/package.go index 2e25994..7a0c6a5 100644 --- a/lib/steam/package.go +++ b/lib/steam/package.go @@ -26,8 +26,7 @@ func (l *Library) PackageGameToFile(index int, file, compress string) error { return err } input := []string{"common/" + g, acf} - a := archive.Archive{Output: output, Input: input} - err = a.Tar(compress) + err = archive.TarToFile(output, input, "gz") if err != nil { return err } @@ -51,10 +50,8 @@ func (l *Library) ExtractGameFromFile(f, compress string) error { if err = os.Chdir(l.Folder); err != nil { return err } - u := &archive.Unarchive{ - Input: f, - } - if err := u.UnTar(compress); err != nil { + + if err := archive.UnTarFromFile(f, compress); err != nil { return err } -- cgit v1.2.3