mirror of
https://github.com/Homebrew/brew.git
synced 2025-07-15 19:56:59 +08:00
Use official?
for checking tap.
This commit is contained in:
parent
05cf8f42e0
commit
6194155765
@ -395,7 +395,7 @@ module Cask
|
|||||||
add_warning "cask token contains .app" if token.end_with? ".app"
|
add_warning "cask token contains .app" if token.end_with? ".app"
|
||||||
|
|
||||||
if /-(?<designation>alpha|beta|rc|release-candidate)$/ =~ cask.token &&
|
if /-(?<designation>alpha|beta|rc|release-candidate)$/ =~ cask.token &&
|
||||||
cask.tap.official? &&
|
cask.tap&.official? &&
|
||||||
cask.tap != "homebrew/cask-versions"
|
cask.tap != "homebrew/cask-versions"
|
||||||
add_warning "cask token contains version designation '#{designation}'"
|
add_warning "cask token contains version designation '#{designation}'"
|
||||||
end
|
end
|
||||||
@ -562,7 +562,7 @@ module Cask
|
|||||||
end
|
end
|
||||||
|
|
||||||
def check_denylist
|
def check_denylist
|
||||||
return if cask.tap&.user != "Homebrew"
|
return unless cask.tap&.official?
|
||||||
return unless reason = Denylist.reason(cask.token)
|
return unless reason = Denylist.reason(cask.token)
|
||||||
|
|
||||||
add_error "#{cask.token} is not allowed: #{reason}"
|
add_error "#{cask.token} is not allowed: #{reason}"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user