diff options
| author | Jack Nagel | 2014-12-10 00:53:57 -0500 |
|---|---|---|
| committer | Jack Nagel | 2014-12-10 00:55:26 -0500 |
| commit | bc0c203934f67624a4a3cd2bd15f1b4eb93b0236 (patch) | |
| tree | c9cfb748ac5f5168b8a27bdd532b97a4715fa055 /Library/Formula | |
| parent | 576258a00a6bf0ca29a3c32f79e4d52ed7a57cd0 (diff) | |
| download | homebrew-bc0c203934f67624a4a3cd2bd15f1b4eb93b0236.tar.bz2 | |
Provide version reader method
Diffstat (limited to 'Library/Formula')
| -rw-r--r-- | Library/Formula/rpm.rb | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/Library/Formula/rpm.rb b/Library/Formula/rpm.rb index 0d685c9c4..ac2fac36b 100644 --- a/Library/Formula/rpm.rb +++ b/Library/Formula/rpm.rb @@ -1,14 +1,10 @@ require 'formula' class RpmDownloadStrategy < CurlDownloadStrategy - def initialize name, resource - super - @tarball_name = "#{name}-#{resource.version}.tar.gz" - end - def stage - safe_system "rpm2cpio.pl <#{cached_location} | cpio -vi #{@tarball_name}" - safe_system "/usr/bin/tar -xzf #{@tarball_name} && rm #{@tarball_name}" + tarball_name = "#{name}-#{version}.tar.gz" + safe_system "rpm2cpio.pl <#{cached_location} | cpio -vi #{tarball_name}" + safe_system "/usr/bin/tar -xzf #{tarball_name} && rm #{tarball_name}" chdir end |
