aboutsummaryrefslogtreecommitdiffstats
path: root/Library
diff options
context:
space:
mode:
authorJack Nagel2012-02-28 18:32:29 -0600
committerJack Nagel2012-02-28 18:35:09 -0600
commit6fe29922c88bbd7b4a0313ccef1d057ea125984f (patch)
tree0af74bc771fdce91a6165f114a025b5d7521c45e /Library
parent571aff35e7b3ec70b574bda40d991535eb12969c (diff)
downloadbrew-6fe29922c88bbd7b4a0313ccef1d057ea125984f.tar.bz2
Set GIT_DIR when staging git clones
Some build scripts want to inspect the git history, e.g. to determine version strings. Rather than copy the repository into the build tree, just setting GIT_DIR is enough for things to "just work". Signed-off-by: Jack Nagel <jacknagel@gmail.com>
Diffstat (limited to 'Library')
-rw-r--r--Library/Homebrew/download_strategy.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/Library/Homebrew/download_strategy.rb b/Library/Homebrew/download_strategy.rb
index 850e72ac7..8b8fcd7c5 100644
--- a/Library/Homebrew/download_strategy.rb
+++ b/Library/Homebrew/download_strategy.rb
@@ -383,6 +383,7 @@ class GitDownloadStrategy < AbstractDownloadStrategy
safe_system 'git', 'submodule', '--quiet', 'foreach', '--recursive', sub_cmd
end
end
+ ENV['GIT_DIR'] = cached_location+'.git'
end
end