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

Cookstyle Bot Auto Corrections with Cookstyle 7.31.1 #69

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

Conversation

cookstyle[bot]
Copy link

@cookstyle cookstyle bot commented Jan 26, 2022

This change is automatically generated by the Cookstyle Bot using the latest version of Cookstyle (7.31.1). Adopting changes suggested by Cookstyle improves cookbook readability, avoids common coding mistakes, and eases upgrades to newer versions of the Chef Infra Client.

Layout/LeadingCommentSpace

Style/StringLiterals

Style/HashSyntax

Layout/EmptyLinesAroundBlockBody

Style/TrailingCommaInHashLiteral

  • /Rakefile:106: Put a comma after the last item of a multiline hash.
  • /libraries/helpers.rb:193: Put a comma after the last item of a multiline hash.
  • /libraries/helpers.rb:199: Put a comma after the last item of a multiline hash.
  • /libraries/helpers.rb:200: Put a comma after the last item of a multiline hash.
  • /libraries/helpers.rb:234: Put a comma after the last item of a multiline hash.
  • /providers/lookup.rb:53: Put a comma after the last item of a multiline hash.
  • /providers/lookup.rb:59: Put a comma after the last item of a multiline hash.

Chef/Style/CommentFormat

Layout/EmptyLinesAroundModuleBody

Layout/CommentIndentation

  • /libraries/helpers.rb:170: Incorrect indentation detected (column 4 instead of 6).

Chef/Modernize/DatabagHelpers

Layout/EmptyLinesAroundMethodBody

Chef/Correctness/IncorrectLibraryInjection

Chef/RedundantCode/LongDescriptionMetadata

Layout/SpaceAroundOperators

Chef/RedundantCode/UnnecessaryNameProperty

Layout/EmptyLines

Signed-off-by: Cookstyle [email protected]

This change is automatically generated by the Cookstyle Bot using the latest version of Cookstyle (7.31.1). Adopting changes suggested by Cookstyle improves cookbook readability, avoids common coding mistakes, and eases upgrades to newer versions of the Chef Infra Client.

### Layout/LeadingCommentSpace
  - **/Berksfile:7**: Missing space after `#`. (https://rubystyle.guide#hash-space)

### Style/StringLiterals
  - **/Rakefile:7**: Prefer single-quoted strings when you don't need string interpolation or special symbols. (https://rubystyle.guide#consistent-string-literals)
  - **/Rakefile:22**: Prefer single-quoted strings when you don't need string interpolation or special symbols. (https://rubystyle.guide#consistent-string-literals)
  - **/Rakefile:35**: Prefer single-quoted strings when you don't need string interpolation or special symbols. (https://rubystyle.guide#consistent-string-literals)
  - **/Rakefile:41**: Prefer single-quoted strings when you don't need string interpolation or special symbols. (https://rubystyle.guide#consistent-string-literals)
  - **/Rakefile:47**: Prefer single-quoted strings when you don't need string interpolation or special symbols. (https://rubystyle.guide#consistent-string-literals)
  - **/Rakefile:53**: Prefer single-quoted strings when you don't need string interpolation or special symbols. (https://rubystyle.guide#consistent-string-literals)
  - **/Rakefile:59**: Prefer single-quoted strings when you don't need string interpolation or special symbols. (https://rubystyle.guide#consistent-string-literals)
  - **/Rakefile:65**: Prefer single-quoted strings when you don't need string interpolation or special symbols. (https://rubystyle.guide#consistent-string-literals)
  - **/Rakefile:67**: Prefer single-quoted strings when you don't need string interpolation or special symbols. (https://rubystyle.guide#consistent-string-literals)
  - **/Rakefile:71**: Prefer single-quoted strings when you don't need string interpolation or special symbols. (https://rubystyle.guide#consistent-string-literals)
  - **/Rakefile:73**: Prefer single-quoted strings when you don't need string interpolation or special symbols. (https://rubystyle.guide#consistent-string-literals)
  - **/Rakefile:77**: Prefer single-quoted strings when you don't need string interpolation or special symbols. (https://rubystyle.guide#consistent-string-literals)
  - **/Rakefile:79**: Prefer single-quoted strings when you don't need string interpolation or special symbols. (https://rubystyle.guide#consistent-string-literals)
  - **/Rakefile:86**: Prefer single-quoted strings when you don't need string interpolation or special symbols. (https://rubystyle.guide#consistent-string-literals)
  - **/Rakefile:92**: Prefer single-quoted strings when you don't need string interpolation or special symbols. (https://rubystyle.guide#consistent-string-literals)
  - **/recipes/deploy_portal.rb:25**: Prefer single-quoted strings when you don't need string interpolation or special symbols. (https://rubystyle.guide#consistent-string-literals)

### Style/HashSyntax
  - **/Rakefile:17**: Use the new Ruby 1.9 hash syntax. (https://rubystyle.guide#hash-literals)
  - **/Rakefile:23**: Use the new Ruby 1.9 hash syntax. (https://rubystyle.guide#hash-literals)
  - **/knife.rb:5**: Use the new Ruby 1.9 hash syntax. (https://rubystyle.guide#hash-literals)
  - **/libraries/helpers.rb:189**: Use the new Ruby 1.9 hash syntax. (https://rubystyle.guide#hash-literals)
  - **/libraries/helpers.rb:190**: Use the new Ruby 1.9 hash syntax. (https://rubystyle.guide#hash-literals)
  - **/libraries/helpers.rb:191**: Use the new Ruby 1.9 hash syntax. (https://rubystyle.guide#hash-literals)
  - **/libraries/helpers.rb:192**: Use the new Ruby 1.9 hash syntax. (https://rubystyle.guide#hash-literals)
  - **/libraries/helpers.rb:193**: Use the new Ruby 1.9 hash syntax. (https://rubystyle.guide#hash-literals)
  - **/libraries/helpers.rb:195**: Use the new Ruby 1.9 hash syntax. (https://rubystyle.guide#hash-literals)
  - **/libraries/helpers.rb:196**: Use the new Ruby 1.9 hash syntax. (https://rubystyle.guide#hash-literals)
  - **/libraries/helpers.rb:197**: Use the new Ruby 1.9 hash syntax. (https://rubystyle.guide#hash-literals)
  - **/libraries/helpers.rb:198**: Use the new Ruby 1.9 hash syntax. (https://rubystyle.guide#hash-literals)
  - **/libraries/helpers.rb:199**: Use the new Ruby 1.9 hash syntax. (https://rubystyle.guide#hash-literals)
  - **/libraries/helpers.rb:206**: Use the new Ruby 1.9 hash syntax. (https://rubystyle.guide#hash-literals)
  - **/resources/lookup.rb:31**: Use the new Ruby 1.9 hash syntax. (https://rubystyle.guide#hash-literals)
  - **/resources/lookup.rb:31**: Use the new Ruby 1.9 hash syntax. (https://rubystyle.guide#hash-literals)
  - **/resources/lookup.rb:32**: Use the new Ruby 1.9 hash syntax. (https://rubystyle.guide#hash-literals)
  - **/resources/lookup.rb:33**: Use the new Ruby 1.9 hash syntax. (https://rubystyle.guide#hash-literals)
  - **/resources/lookup.rb:34**: Use the new Ruby 1.9 hash syntax. (https://rubystyle.guide#hash-literals)
  - **/resources/lookup.rb:35**: Use the new Ruby 1.9 hash syntax. (https://rubystyle.guide#hash-literals)
  - **/resources/lookup.rb:36**: Use the new Ruby 1.9 hash syntax. (https://rubystyle.guide#hash-literals)

### Layout/EmptyLinesAroundBlockBody
  - **/Rakefile:82**: Extra empty line detected at block body end. (https://rubystyle.guide#empty-lines-around-bodies)

### Style/TrailingCommaInHashLiteral
  - **/Rakefile:106**: Put a comma after the last item of a multiline hash.
  - **/libraries/helpers.rb:193**: Put a comma after the last item of a multiline hash.
  - **/libraries/helpers.rb:199**: Put a comma after the last item of a multiline hash.
  - **/libraries/helpers.rb:200**: Put a comma after the last item of a multiline hash.
  - **/libraries/helpers.rb:234**: Put a comma after the last item of a multiline hash.
  - **/providers/lookup.rb:53**: Put a comma after the last item of a multiline hash.
  - **/providers/lookup.rb:59**: Put a comma after the last item of a multiline hash.

### Chef/Style/CommentFormat
  - **/libraries/helpers.rb:1**: Properly format header comments (https://docs.chef.io/workstation/cookstyle/chef_style_commentformat)
  - **/providers/lookup.rb:2**: Properly format header comments (https://docs.chef.io/workstation/cookstyle/chef_style_commentformat)
  - **/recipes/_destroy_portal_key.rb:1**: Properly format header comments (https://docs.chef.io/workstation/cookstyle/chef_style_commentformat)
  - **/recipes/_destroy_security_groups.rb:1**: Properly format header comments (https://docs.chef.io/workstation/cookstyle/chef_style_commentformat)
  - **/recipes/_refresh_portal.rb:1**: Properly format header comments (https://docs.chef.io/workstation/cookstyle/chef_style_commentformat)
  - **/recipes/_setup_portal_key.rb:1**: Properly format header comments (https://docs.chef.io/workstation/cookstyle/chef_style_commentformat)
  - **/recipes/_setup_security_groups.rb:1**: Properly format header comments (https://docs.chef.io/workstation/cookstyle/chef_style_commentformat)
  - **/recipes/chef_server.rb:1**: Properly format header comments (https://docs.chef.io/workstation/cookstyle/chef_style_commentformat)
  - **/recipes/default.rb:1**: Properly format header comments (https://docs.chef.io/workstation/cookstyle/chef_style_commentformat)
  - **/recipes/deploy_chef_server.rb:1**: Properly format header comments (https://docs.chef.io/workstation/cookstyle/chef_style_commentformat)
  - **/recipes/deploy_first_nodes.rb:1**: Properly format header comments (https://docs.chef.io/workstation/cookstyle/chef_style_commentformat)
  - **/recipes/deploy_multi_nodes.rb:1**: Properly format header comments (https://docs.chef.io/workstation/cookstyle/chef_style_commentformat)
  - **/recipes/deploy_portal.rb:1**: Properly format header comments (https://docs.chef.io/workstation/cookstyle/chef_style_commentformat)
  - **/recipes/deploy_workstations.rb:1**: Properly format header comments (https://docs.chef.io/workstation/cookstyle/chef_style_commentformat)
  - **/recipes/destroy_chef_server.rb:1**: Properly format header comments (https://docs.chef.io/workstation/cookstyle/chef_style_commentformat)
  - **/recipes/destroy_lab.rb:1**: Properly format header comments (https://docs.chef.io/workstation/cookstyle/chef_style_commentformat)
  - **/recipes/destroy_nodes.rb:1**: Properly format header comments (https://docs.chef.io/workstation/cookstyle/chef_style_commentformat)
  - **/recipes/destroy_portal.rb:1**: Properly format header comments (https://docs.chef.io/workstation/cookstyle/chef_style_commentformat)
  - **/recipes/destroy_workstations.rb:1**: Properly format header comments (https://docs.chef.io/workstation/cookstyle/chef_style_commentformat)
  - **/resources/lookup.rb:2**: Properly format header comments (https://docs.chef.io/workstation/cookstyle/chef_style_commentformat)
  - **/spec/unit/recipes/default_spec.rb:2**: Properly format header comments (https://docs.chef.io/workstation/cookstyle/chef_style_commentformat)
  - **/spec/unit/recipes/default_spec.rb:5**: Properly format header comments (https://docs.chef.io/workstation/cookstyle/chef_style_commentformat)

### Layout/EmptyLinesAroundModuleBody
  - **/libraries/helpers.rb:5**: Extra empty line detected at module body beginning. (https://rubystyle.guide#empty-lines-around-bodies)

### Layout/CommentIndentation
  - **/libraries/helpers.rb:170**: Incorrect indentation detected (column 4 instead of 6).

### Chef/Modernize/DatabagHelpers
  - **/libraries/helpers.rb:215**: Use the `data_bag_item` helper instead of `Chef::DataBagItem.load` or `Chef::EncryptedDataBagItem.load`. (https://docs.chef.io/workstation/cookstyle/chef_modernize_databaghelpers)

### Layout/EmptyLinesAroundMethodBody
  - **/libraries/helpers.rb:221**: Extra empty line detected at method body beginning. (https://rubystyle.guide#empty-lines-around-bodies)

### Chef/Correctness/IncorrectLibraryInjection
  - **/libraries/helpers.rb:250**: Libraries should be injected into the Chef::DSL::Recipe class and not Chef::Recipe or Chef::Provider classes directly. (https://docs.chef.io/workstation/cookstyle/chef_correctness_incorrectlibraryinjection)

### Chef/RedundantCode/LongDescriptionMetadata
  - **/metadata.rb:6**: The long_description metadata.rb method is not used and is unnecessary in cookbooks. (https://docs.chef.io/workstation/cookstyle/chef_redundantcode_longdescriptionmetadata)

### Layout/SpaceAroundOperators
  - **/recipes/_setup_security_groups.rb:27**: Operator `=>` should be surrounded by a single space. (https://rubystyle.guide#spaces-operators)

### Chef/RedundantCode/UnnecessaryNameProperty
  - **/resources/lookup.rb:31**: There is no need to define a property or attribute named :name in a resource as Chef Infra defines this on all resources by default. (https://docs.chef.io/workstation/cookstyle/chef_redundantcode_unnecessarynameproperty)

### Layout/EmptyLines
  - **/resources/lookup.rb:31**: Extra blank line detected. (https://rubystyle.guide#two-or-more-empty-lines)

Signed-off-by: Cookstyle <[email protected]>
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.

0 participants