Skip to content

Commit

Permalink
style: fix tap checking
Browse files Browse the repository at this point in the history
`brew style` tap support was broken in 7d0ac4d (#17357), so now
something like `brew style homebrew/core` exits without checking
anything. This happens because the new file-handling logic doesn't
do anything with a tap path. Previously, a tap path would be added
to `ruby_files` but now it isn't added to any of the arrays of files
to check.

This fixes the issue by adding some logic to add the path to the
`ruby_files` array if it's a tap.
  • Loading branch information
samford committed Jun 12, 2024
1 parent a820399 commit f815e34
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions Library/Homebrew/style.rb
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ def self.check_style_impl(files, output_type,
when ".yml"
actionlint_files << path if path.realpath.to_s.include?("/.github/workflows/")
else
ruby_files << path if path.tap?
shell_files << path if path.realpath == HOMEBREW_BREW_FILE.realpath
end
end
Expand Down

0 comments on commit f815e34

Please sign in to comment.