You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Doesn't seem to work as expected, and instead when calculated in rubocop, ends up with the following (the following is some debug output from me working on ManageIQ/miq_bot#500 that I "puts debugged" from the rubocop gem directly):
Don't have an answer on how to fix this properly (besides just removing this and adding it to all the repos manually), but figured it should be made known prior to pushing out something like ManageIQ/miq_bot#506 to all the repos.
The text was updated successfully, but these errors were encountered:
When Excludes are present in an inherited configuration file, Rubocop
will expand_path them. However, the Excludes in .rubocop_base.yml were
being resolved relative to the gem itself. Because of this they were
ultimately ignored.
The reason this happens is because Rubocop looks at the filename, and if
it starts with .rubocop, it assumes that is a project-level file, and
will expand relative to the file itself. Rubocop's own default config
intentionally does _not_ start with .rubocop, as so the default config
is expanded relative to the project. See
https://github.com/rubocop-hq/rubocop/blob/eb3d3583/lib/rubocop/config.rb#L190-L203
The simplest fix for now is to just rename our files to not have
.rubocop at the start of the file name. We can still keep our
.rubocop_base.yml to avoid renaming it in all of the gems.
FixesManageIQ#7ClosesManageIQ#8
The following configuration:
manageiq-style/.rubocop_base.yml
Lines 7 to 9 in 16e9c31
Doesn't seem to work as expected, and instead when calculated in
rubocop
, ends up with the following (the following is some debug output from me working on ManageIQ/miq_bot#500 that I "puts
debugged" from therubocop
gem directly):Don't have an answer on how to fix this properly (besides just removing this and adding it to all the repos manually), but figured it should be made known prior to pushing out something like ManageIQ/miq_bot#506 to all the repos.
The text was updated successfully, but these errors were encountered: