-
Notifications
You must be signed in to change notification settings - Fork 194
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
Getting rid of rubocop offenses #945
Comments
* Things like array.each &:method are ambiguous in a sense that a simple white space would make it be a bitwise and. Adding parens makes it clearer, although I don't like parens so much * Same thing goes for splates etc. * #945
* Sometimes whole side effect less method calls were just leftovers and hence deleted * #945
* parens for better clarity * avoid shadowing of variables * useless public/private modifiers * variable that starts with _ should not be used * couple of harder things remaining (eval/Exception) * #945
Hey Tobias. I've forked this and am going to get started squashing these. This'll be my first open-source contrib so I'm very excited! |
Hurray, thanks for the help @Zanadar! If you didn't pull already this afternoon, highly recommend you do before you start. We just merged an epic file move, and would hate for your efforts to hit unneeded merge conflicts! Shoes on! ✨ |
Hey @Zanadar that sounds amazing! Looking forward to your contribution very much :) I just checked and your fork has the state from after the epic file move, so that is good - get squashing away! Also, feel free to do early pull requests :) We love to review and refine together! Thanks! |
@Zanadar Have you got a PR youre still going to submit or have you stopped working on it? I was planning on hopping onto it myself. |
I don't see changes on the repo so I think it's safe to hack on it :) Also, there are enough rubocop offences for everyone :D Tobi |
For the cops that seem questionable, should I ask about them here inline or open new tickets for each one? |
We did a basic review of the rules when we opened this and excluded the ones we clearly didn't want, but it's very possible others are questionable. I'd say go for it with separate issues/PR's for any that you've got question on. That's a great way to discuss them. |
👍 |
Fixed minor Rubocop Issues (Issue shoes#945)
Note for anyone wanting to contribute to this issue: All existing violations are recorded in |
Hi, even the Hacktoberfest label is from the last year, it should be valid to fix some rubocop offenes, right? :) |
Totally still valid! Thanks @submitnine. |
Rubocop is a tool that automatically checks for ruby style violations. We ran an autofix but still got a couple of them in here.
If you want, you can help by getting rid of a couple of them, which would be appreciated 👍
Here is a nice website that shows an overview: http://www.refactorcop.com/shoes/shoes4
In case we don't like some of them, we might also deactivate them so rubocop doesn't scan for them any more.
Here is a current list of the offenses we have, generated through
rubocop lib/ --format offenses -D --out rubocop_offenses.txt
:And here is a gist with a detailed analysis of what went wrong generated through
rubocop lib/ -D --out rubocop.txt
rubocop gistSome time I'll probably go and check out the linting ones and others.
The text was updated successfully, but these errors were encountered: