aboutsummaryrefslogtreecommitdiffstats
path: root/Library
diff options
context:
space:
mode:
authorMike McQuaid2016-12-23 19:42:31 +0000
committerGitHub2016-12-23 19:42:31 +0000
commit9bfeb91562e8269ed14bcb55dee5d99b6b19840e (patch)
treead07d7232ea3445567ce4a8eedd60123416dff8b /Library
parent161bd20fcdc2af6b582c4a617b04c4c300f8bf82 (diff)
parent3ebd7df62d0b05a8a010bec74793cc4e688a2fc8 (diff)
downloadbrew-9bfeb91562e8269ed14bcb55dee5d99b6b19840e.tar.bz2
Merge pull request #1715 from zmwangx/bump-formula-pr-fix-removal-of-old-mirror
bump-formula-pr: fix removal of old mirrors
Diffstat (limited to 'Library')
-rw-r--r--Library/Homebrew/dev-cmd/bump-formula-pr.rb4
1 files changed, 3 insertions, 1 deletions
diff --git a/Library/Homebrew/dev-cmd/bump-formula-pr.rb b/Library/Homebrew/dev-cmd/bump-formula-pr.rb
index b1f851b8d..8fdbd97b6 100644
--- a/Library/Homebrew/dev-cmd/bump-formula-pr.rb
+++ b/Library/Homebrew/dev-cmd/bump-formula-pr.rb
@@ -156,7 +156,9 @@ module Homebrew
replacement_pairs << [/^ revision \d+\n(\n( head "))?/m, "\\2"]
end
- replacement_pairs << [/(^ mirror .*\n)?/, ""] if requested_spec == :stable
+ replacement_pairs += formula_spec.mirrors.map do |mirror|
+ [/ +mirror \"#{mirror}\"\n/m, ""]
+ end
replacement_pairs += if new_url_hash
[