diff options
| author | Xu Cheng | 2016-04-03 00:27:44 +0800 |
|---|---|---|
| committer | Xu Cheng | 2016-04-03 00:34:09 +0800 |
| commit | bdd26d04468e6bbd3cf5e9841a1f163d33884e67 (patch) | |
| tree | 0030d778ccb14eac0e4a3532eb010627b5b08b05 | |
| parent | 4366ea1889b94f2b06b11c6a018e287f5b108712 (diff) | |
| download | brew-bdd26d04468e6bbd3cf5e9841a1f163d33884e67.tar.bz2 | |
test-bot: ensure tap is full clone
| -rw-r--r-- | Library/Homebrew/cmd/test-bot.rb | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/Library/Homebrew/cmd/test-bot.rb b/Library/Homebrew/cmd/test-bot.rb index 71259d677..a30a85e6a 100644 --- a/Library/Homebrew/cmd/test-bot.rb +++ b/Library/Homebrew/cmd/test-bot.rb @@ -874,9 +874,17 @@ module Homebrew p ARGV tap = resolve_test_tap - # Tap repository if required, this is done before everything else - # because Formula parsing and/or git commit hash lookup depends on it. - safe_system "brew", "tap", tap.name unless tap.installed? + if tap.installed? + # make sure Tap is not a shallow clone. + # bottle revision and bottle upload rely on full clone. + if (tap.path/".git/shallow").exist? + safe_system "git", "-C", tap.path, "fetch", "--unshallow" + end + else + # Tap repository if required, this is done before everything else + # because Formula parsing and/or git commit hash lookup depends on it. + safe_system "brew", "tap", tap.name, "--full" + end if ARGV.include? "--ci-upload" return test_ci_upload(tap) |
