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
Problem in Gemfile-less folder #6939
Labels
Comments
koic
added a commit
to koic/rubocop
that referenced
this issue
Apr 17, 2019
Fixes rubocop#6939. Fixes rubocop#6917. This warning should not be displayed if users don't use Performance cops as follows: - rubocop#6845 (comment) - rubocop#6919 (comment) In the future, it will be better to replace it with a mechanism that displays a warning only when the user need Performance cops. This PR removes a warning for rubocop-performance when runinng `rubocop` command. It just leave a warning just to `gem install rubocop`. https://github.com/rubocop-hq/rubocop/blob/v0.67.2/rubocop.gemspec#L47
8 tasks
Thanks for the feedback. I opened a PR #6944. |
This was referenced Apr 17, 2019
bbatsov
pushed a commit
that referenced
this issue
Apr 17, 2019
Fixes #6939. Fixes #6917. This warning should not be displayed if users don't use Performance cops as follows: - #6845 (comment) - #6919 (comment) In the future, it will be better to replace it with a mechanism that displays a warning only when the user need Performance cops. This PR removes a warning for rubocop-performance when running `rubocop` command. It leaves a warning just for `gem install rubocop`. https://github.com/rubocop-hq/rubocop/blob/v0.67.2/rubocop.gemspec#L47
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
In a small folder with only one file (even empty one), attempt to run
rubocop file.rb
now leads to:The problem is here: https://github.com/rubocop-hq/rubocop/blob/master/exe/rubocop#L12
Rubocop assumes that if the
Bundler
constant is defined, it should be able to load a Gemfile. It proves to be generally wrong, at least on my system,Bundler
constant gets defined in RubyGem'sruby_executable_hooks
executable.Environment:
The text was updated successfully, but these errors were encountered: