unpack: expand destdir in case a relative path is given

Fixes Homebrew/homebrew#38067.
This commit is contained in:
Jack Nagel 2015-03-25 22:22:51 -04:00
parent 038332d8d7
commit 60fe954bfd

View File

@ -13,7 +13,7 @@ module Homebrew
raise FormulaUnspecifiedError if formulae.empty?
if dir = ARGV.value("destdir")
unpack_dir = Pathname.new(dir)
unpack_dir = Pathname.new(dir).expand_path
unpack_dir.mkpath
else
unpack_dir = Pathname.pwd