rubocops/patches: Make more GitHub patch locations enforce revisions
- We recently deleted a load of old Homebrew/formula-patches patches for non-existent core formulae (https://github.com/Homebrew/formula-patches/pull/283). This is a good action to take. Users should always be able to retrieve the patch once it's been deleted from the repo, if the formula they continue to use specifies a git revision to pull from, not just `master`. - The code to detect `master` formulae was already here, so this adds another GitHub host to the detection: `raw.githubusercontent.com` as that's what the current patches that use `master` (https://github.com/Homebrew/homebrew-core/pull/51329) link to. - Fixes https://github.com/Homebrew/homebrew-core/issues/51313.
This commit is contained in:
parent
19050bd738
commit
9f80a7bce2
@ -39,6 +39,7 @@ module RuboCop
|
||||
end
|
||||
|
||||
gh_patch_patterns = Regexp.union([%r{/raw\.github\.com/},
|
||||
%r{/raw\.githubusercontent\.com/},
|
||||
%r{gist\.github\.com/raw},
|
||||
%r{gist\.github\.com/.+/raw},
|
||||
%r{gist\.githubusercontent\.com/.+/raw}])
|
||||
|
Loading…
x
Reference in New Issue
Block a user