-
Notifications
You must be signed in to change notification settings - Fork 449
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
Use chefstyle 0.4.0 for linting and resolve all warnings #870
Conversation
Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
there's some voodoo going on here i don't want to figure out how to unwind Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
@@ -177,7 +177,7 @@ def popen4(cmd, args = {}, &b) | |||
$VERBOSE = nil | |||
ps.last.fcntl(Fcntl::F_SETFD, Fcntl::FD_CLOEXEC) | |||
|
|||
cid = fork { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
might as well fix it, but this is hopefully getting deleted soon
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
rubocop fixed it for me with -a
Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
cpu[current_cpu]["stepping"] = processor["stepping"].nil? \ | ||
? processor["description"].match(/Stepping\s+(\d+)/)[1] \ | ||
: processor["stepping"] | ||
cpu[current_cpu]["stepping"] = if processor["stepping"].nil? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Killing these multiline operators is fantastic. They're a real pain to read
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you didn't see the one in chef/chef where someone used a multiline ternary and broke a string in the middle with \ in order to line wrap it and get it under 80 columns. completely unreadable omgwtfbbq.
this example is just from someone who didn't understand whitespace parsing and tokenization in ruby...
fixing some of these methods to be private (when they were intended to be private but were actually public) broke tests. Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
this is actually passing but chefstyle is bitching about Lint/UnnededDisable which is a rule that i'll disable for chefstyle 0.4.0 to make this annoyance stop. |
Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
fixing all the new enforcement with chefstyle 0.4.0