Skip to content

Commit

Permalink
RuboCop auto-corrections and config regen
Browse files Browse the repository at this point in the history
  • Loading branch information
meatballhat committed Nov 23, 2015
1 parent 8f45585 commit 972bdf6
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 25 deletions.
19 changes: 5 additions & 14 deletions cookbooks/.rubocop_todo.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# This configuration was generated by
# `rubocop --auto-gen-config`
# on 2015-10-30 08:16:03 +0100 using RuboCop version 0.34.2.
# on 2015-11-23 11:15:06 -0500 using RuboCop version 0.35.1.
# The point is for the user to remove these configuration records
# one by one as the offenses are removed from the code base.
# Note that changes in the inspected code, or installation of new
Expand All @@ -27,20 +27,17 @@ Lint/UselessAssignment:

# Offense count: 1
Metrics/AbcSize:
Exclude:
- 'travis_java/libraries/oraclejdk.rb'
Max: 36

# Offense count: 254
# Offense count: 241
# Configuration parameters: AllowURI, URISchemes.
Metrics/LineLength:
Max: 317

# Offense count: 2
# Offense count: 3
# Configuration parameters: CountComments.
Metrics/MethodLength:
Exclude:
- 'travis_python/providers/pip.rb'
- 'travis_java/libraries/oraclejdk.rb'
Max: 31

# Offense count: 4
# Configuration parameters: Exclude.
Expand All @@ -56,9 +53,3 @@ Style/FileName:
Style/FormatString:
Exclude:
- 'travis_jupiter_brain/recipes/default.rb'

# Offense count: 1
# Configuration parameters: EnforcedStyle, MinBodyLength, SupportedStyles.
Style/Next:
Exclude:
- 'nodejs/recipes/multi.rb'
21 changes: 10 additions & 11 deletions cookbooks/nodejs/recipes/multi.rb
Original file line number Diff line number Diff line change
Expand Up @@ -55,17 +55,16 @@
end

node['nodejs']['default_modules'].each do |mod|
if Gem::Version.new(version) >= Gem::Version.new(mod['required'])
bash "install #{mod[:module]} for node version #{version}" do
code "#{nvm} use #{version}; npm install -g #{mod['module']}"
creates "#{node['travis_build_environment']['home']}/.nvm/#{version}/lib/node_modules/#{mod['module']}"
user node['travis_build_environment']['user']
group node['travis_build_environment']['group']
cwd node['travis_build_environment']['home']
environment(
'HOME' => node['travis_build_environment']['home']
)
end
next unless Gem::Version.new(version) >= Gem::Version.new(mod['required'])
bash "install #{mod[:module]} for node version #{version}" do
code "#{nvm} use #{version}; npm install -g #{mod['module']}"
creates "#{node['travis_build_environment']['home']}/.nvm/#{version}/lib/node_modules/#{mod['module']}"
user node['travis_build_environment']['user']
group node['travis_build_environment']['group']
cwd node['travis_build_environment']['home']
environment(
'HOME' => node['travis_build_environment']['home']
)
end
end
end
Expand Down

0 comments on commit 972bdf6

Please sign in to comment.