Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

audit: disallow devel specs in core #5086

Merged
merged 1 commit into from
Oct 20, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
14 changes: 9 additions & 5 deletions Library/Homebrew/dev-cmd/audit.rb
Original file line number Diff line number Diff line change
Expand Up @@ -663,17 +663,21 @@ def audit_specs
end
end

if @core_tap && (formula.head || formula.devel)
unstable_spec_message = "Formulae should not have a `HEAD` or `devel` spec"
if @core_tap && formula.devel
problem "Formulae should not have a `devel` spec"
end

if @core_tap && formula.head
head_spec_message = "Formulae should not have a `HEAD` spec"
if @new_formula
new_formula_problem unstable_spec_message
new_formula_problem head_spec_message
elsif @versioned_formula
versioned_unstable_spec = %w[
versioned_head_spec = %w[
bash-completion@2
imagemagick@6
python@2
]
problem unstable_spec_message unless versioned_unstable_spec.include?(formula.name)
problem head_spec_message unless versioned_head_spec.include?(formula.name)
end
end

Expand Down