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

Fix a ruby warning when executing with bundle exec rubocop in this repository #288

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Earlopain
Copy link
Contributor

check_commit.rake requires 'English' but when doing bundle exec rubocop this repository this file will also be evaluated.

This also happens in the rubocop repository (my main motivation here) if rubocop-ast is in the parent folder because of this line in its Gemfile: https://github.com/rubocop/rubocop/blob/66c8276b5d9e60fed1fb8d937649c3c153e5037d/Gemfile#L29-L30

$ RUBYOPT=-w bundle exec rubocop -V
.../rubocop-ast/rubocop-ast.gemspec:18: warning: global variable `$RS' not initialized
1.62.1 (using Parser 3.3.0.5, rubocop-ast 1.31.2, running on ruby 3.3.0) [x86_64-linux]
  - rubocop-performance 1.20.2
  - rubocop-rspec 2.27.1

@koic
Copy link
Member

koic commented Mar 14, 2024

Can you update to another approach that avoids using $RS in s.files= of the rubocop-ast gemspec, instead of requiring English?

`check_commit.rake` requires 'English' but when doing `bundle exec rubocop` this file will also be evaluated.

```
earlopain@DESKTOP-PC rubocop-ast]$ RUBYOPT=-w bundle exec rubocop -V
/home/earlopain/Documents/rubocop-ast/rubocop-ast.gemspec:18: warning: global variable `$RS' not initialized
1.62.1 (using Parser 3.3.0.5, rubocop-ast 1.31.2, running on ruby 3.3.0) [x86_64-linux]
  - rubocop-performance 1.20.2
  - rubocop-rspec 2.27.1
```
@Earlopain
Copy link
Contributor Author

Yeah, sure. Updated

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants