diff options
| author | Xu Cheng | 2015-09-18 21:44:49 +0800 |
|---|---|---|
| committer | Xu Cheng | 2015-09-18 22:04:24 +0800 |
| commit | 347a215361931898db0b74675c1c744816324cb2 (patch) | |
| tree | dbf291d98c5303850203e2fb8ab84d52d47de808 /Library | |
| parent | 4114a75039395e51fdfaa074a98a52fe0c623f37 (diff) | |
| download | brew-347a215361931898db0b74675c1c744816324cb2.tar.bz2 | |
test-bot: better fold id for travis
* Only use first two word in command to keep id short
* Append unique number in the id.
Closes Homebrew/homebrew#44104.
Signed-off-by: Xu Cheng <xucheng@me.com>
Diffstat (limited to 'Library')
| -rw-r--r-- | Library/Homebrew/cmd/test-bot.rb | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/Library/Homebrew/cmd/test-bot.rb b/Library/Homebrew/cmd/test-bot.rb index d98b4bbdc..f3725cbea 100644 --- a/Library/Homebrew/cmd/test-bot.rb +++ b/Library/Homebrew/cmd/test-bot.rb @@ -100,8 +100,10 @@ module Homebrew def puts_command if ENV["TRAVIS"] + @@travis_step_num ||= 0 + @travis_fold_id = @command.first(2).join(".") + ".#{@@travis_step_num += 1}" @travis_timer_id = rand(2**32).to_s(16) - puts "travis_fold:start:#{@command.join(".")}" + puts "travis_fold:start:#{@travis_fold_id}" puts "travis_time:start:#{@travis_timer_id}" end puts "#{Tty.blue}==>#{Tty.white} #{@command.join(" ")}#{Tty.reset}" @@ -114,7 +116,7 @@ module Homebrew travis_duration = travis_end_time - travis_start_time puts "#{Tty.white}==>#{Tty.green} PASSED#{Tty.reset}" if passed? puts "travis_time:end:#{@travis_timer_id},start=#{travis_start_time},finish=#{travis_end_time},duration=#{travis_duration}" - puts "travis_fold:end:#{@command.join(".")}" + puts "travis_fold:end:#{@travis_fold_id}" end puts "#{Tty.white}==>#{Tty.red} FAILED#{Tty.reset}" if failed? end |
