aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew
diff options
context:
space:
mode:
authorMartin Kühl2010-09-12 22:55:52 +0200
committerAdam Vandenberg2010-09-19 11:11:56 -0700
commit730cd0e6fea17d7e5df511b2c1fce4d70c197167 (patch)
treed74594da7cb5940d5d6fb67ba38b996b2af59bdd /Library/Homebrew
parent389fdec9d4889401a32b2ff6015902cad308ff71 (diff)
downloadbrew-730cd0e6fea17d7e5df511b2c1fce4d70c197167.tar.bz2
Let the `gzip` utility function accept multiple paths.
Signed-off-by: Adam Vandenberg <flangy@gmail.com>
Diffstat (limited to 'Library/Homebrew')
-rw-r--r--Library/Homebrew/utils.rb8
1 files changed, 5 insertions, 3 deletions
diff --git a/Library/Homebrew/utils.rb b/Library/Homebrew/utils.rb
index 0c2e4de8b..4d426a9bf 100644
--- a/Library/Homebrew/utils.rb
+++ b/Library/Homebrew/utils.rb
@@ -165,9 +165,11 @@ def exec_editor *args
end
# GZips the given path, and returns the gzipped file
-def gzip path
- system "/usr/bin/gzip", path
- return Pathname.new(path+".gz")
+def gzip *paths
+ paths.collect do |path|
+ system "/usr/bin/gzip", path
+ Pathname.new(path+".gz")
+ end
end
module ArchitectureListExtension