From 307ea17ba3adde76508c8d57c2ac3ad5c418dfc4 Mon Sep 17 00:00:00 2001 From: Mike McQuaid Date: Fri, 27 Feb 2015 13:53:29 +0000 Subject: test-bot: cleanup old PR locks. This is a problem on older versions of Git (such as on the Mountain Lion bot). --- Library/Homebrew/cmd/test-bot.rb | 2 ++ 1 file changed, 2 insertions(+) (limited to 'Library/Homebrew/cmd/test-bot.rb') diff --git a/Library/Homebrew/cmd/test-bot.rb b/Library/Homebrew/cmd/test-bot.rb index 8ea39bf5c..b7a9ad384 100644 --- a/Library/Homebrew/cmd/test-bot.rb +++ b/Library/Homebrew/cmd/test-bot.rb @@ -513,6 +513,8 @@ module Homebrew git "checkout", "-f", "master" git "clean", "-fdx" git "clean", "-ffdx" unless $?.success? + pr_locks = "#{HOMEBREW_REPOSITORY}/.git/refs/remotes/*/pr/*/head.lock" + Dir.glob(pr_locks) {|lock| FileUtils.rm_rf lock } end def cleanup_after -- cgit v1.2.3