Move gz-only strategy into core.

This commit is contained in:
Adam Vandenberg 2011-05-19 07:37:24 -07:00
parent f8127143cf
commit 206c370d74

View File

@ -143,6 +143,14 @@ class NoUnzipCurlDownloadStrategy < CurlDownloadStrategy
end
end
# Normal strategy tries to untar as well
class GzipOnlyDownloadStrategy < CurlDownloadStrategy
def stage
FileUtils.mv @tarball_path, File.basename(@url)
safe_system '/usr/bin/gunzip', '-f', File.basename(@url)
end
end
# This Download Strategy is provided for use with sites that
# only provide HTTPS and also have a broken cert.
# Try not to need this, as we probably won't accept the formula.