audit: fix gist patch URL regex
Closes Homebrew/homebrew#27255. Signed-off-by: Jack Nagel <jacknagel@gmail.com> Conflicts: Library/Homebrew/cmd/audit.rb
This commit is contained in:
parent
7f33a84ce6
commit
9bbe38aa59
@ -304,7 +304,7 @@ class FormulaAuditor
|
|||||||
|
|
||||||
def audit_patch(patch)
|
def audit_patch(patch)
|
||||||
case patch.url
|
case patch.url
|
||||||
when %r[raw\.github\.com], %r[gist\.github\.com/raw], %r[gist\.github\.com/.+/raw$]
|
when %r[raw\.github\.com], %r[gist\.github\.com/raw], %r[gist\.github\.com/.+/raw]
|
||||||
unless patch.url =~ /[a-fA-F0-9]{40}/
|
unless patch.url =~ /[a-fA-F0-9]{40}/
|
||||||
problem "GitHub/Gist patches should specify a revision:\n#{patch.url}"
|
problem "GitHub/Gist patches should specify a revision:\n#{patch.url}"
|
||||||
end
|
end
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user