From c3739dc441604a7a929da5c9b3f2818981a968b2 Mon Sep 17 00:00:00 2001 From: Mike McQuaid Date: Fri, 29 Jul 2016 15:54:56 -0600 Subject: [PATCH] utils/bottles: don't rely on tar wildcards, location. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This doesn’t work quite as-is on Linux’s GNU tar. --- Library/Homebrew/utils/bottles.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Library/Homebrew/utils/bottles.rb b/Library/Homebrew/utils/bottles.rb index 7b40a2e41e..d1798ecc95 100644 --- a/Library/Homebrew/utils/bottles.rb +++ b/Library/Homebrew/utils/bottles.rb @@ -29,7 +29,9 @@ module Utils end def receipt_path(bottle_file) - Utils.popen_read("/usr/bin/tar", "-tzf", bottle_file, "*/*/INSTALL_RECEIPT.json").chomp + Utils.popen_read("tar", "-tzf", bottle_file).lines.map(&:chomp).find do |line| + line =~ %r{.+/.+/INSTALL_RECEIPT.json} + end end def resolve_formula_names(bottle_file)