-
Notifications
You must be signed in to change notification settings - Fork 2
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
Rubocop and comment out unneeded gems #29
Merged
Merged
Changes from all commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
inherit_from: .rubocop_todo.yml | ||
|
||
# Turn on RSpec cops | ||
require: rubocop-rspec | ||
|
||
AllCops: | ||
DisplayCopNames: true | ||
Include: | ||
- Rakefile | ||
- config.ru | ||
- lib/**/*.rake | ||
Exclude: | ||
- 'Gemfile.lock' | ||
- '**/*.md' | ||
- 'bin/**/*' | ||
- 'config/**/*.yml' | ||
- 'db/**/*' | ||
- 'script/**/*' | ||
- 'vendor/**/*' | ||
|
||
# Turn on Rails cops | ||
Rails: | ||
Enabled: true | ||
|
||
Metrics/BlockLength: | ||
Exclude: | ||
- 'spec/**/*' | ||
|
||
# because this isn't 1994 | ||
Metrics/LineLength: | ||
Max: 120 | ||
|
||
Metrics/MethodLength: | ||
Max: 20 | ||
|
||
Layout/EmptyLinesAroundBlockBody: | ||
Enabled: false | ||
|
||
Layout/EmptyLinesAroundClassBody: | ||
Enabled: false | ||
|
||
Layout/EmptyLinesAroundModuleBody: | ||
Enabled: false | ||
|
||
Style/StringLiterals: | ||
Enabled: false | ||
|
||
Style/SymbolArray: | ||
Enabled: false | ||
|
||
RSpec/MultipleExpectations: | ||
Exclude: | ||
- 'spec/controllers/moab_storage_controller_spec.rb' | ||
|
||
|
||
Bundler/OrderedGems: | ||
Exclude: | ||
- 'Gemfile' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
# This configuration was generated by | ||
# `rubocop --auto-gen-config` | ||
# on 2017-08-23 17:50:12 -0700 using RuboCop version 0.49.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 | ||
# versions of RuboCop, may require this file to be generated again. | ||
|
||
# Offense count: 2 | ||
# Cop supports --auto-correct. | ||
Layout/SpaceInsideBrackets: | ||
Exclude: | ||
- 'config/environments/production.rb' | ||
|
||
# Offense count: 1 | ||
Rails/FilePath: | ||
Exclude: | ||
- 'config/environments/development.rb' | ||
|
||
# Offense count: 1 | ||
# Cop supports --auto-correct. | ||
Style/BlockComments: | ||
Exclude: | ||
- 'spec/spec_helper.rb' | ||
|
||
# Offense count: 5 | ||
Style/Documentation: | ||
Exclude: | ||
- 'spec/**/*' | ||
- 'test/**/*' | ||
- 'app/controllers/application_controller.rb' | ||
- 'app/helpers/application_helper.rb' | ||
- 'app/mailers/application_mailer.rb' | ||
- 'app/models/application_record.rb' | ||
- 'config/application.rb' | ||
|
||
# Offense count: 1 | ||
# Configuration parameters: ExpectMatchingDefinition, Regex, IgnoreExecutableScripts, AllowedAcronyms. | ||
# AllowedAcronyms: CLI, DSL, ACL, API, ASCII, CPU, CSS, DNS, EOF, GUID, HTML, HTTP, HTTPS, ID, IP, JSON, LHS, QPS, RAM, RHS, RPC, SLA, SMTP, SQL, SSH, TCP, TLS, TTL, UDP, UI, UID, UUID, URI, URL, UTF8, VM, XML, XMPP, XSRF, XSS | ||
Style/FileName: | ||
Exclude: | ||
- 'Gemfile' | ||
|
||
# Offense count: 1 | ||
# Cop supports --auto-correct. | ||
# Configuration parameters: PreferredDelimiters. | ||
Style/PercentLiteralDelimiters: | ||
Exclude: | ||
- 'config/spring.rb' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
Why not just delete instead of comment out?
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.
Excellent question! All of this stuff was added by the rails generator, including pinning to versions. I was feeling tentative, so I commented stuff out. I would be happy to remove cruft if we prefer -- we can always get it back from git history or another rails app if we need it. What do you think?
See also #30 which is about removing directories and the like for unused stuff -- are we comfy with removing all this stuff?
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.
My opinion on this one is that we might as well remove this stuff from the Gemfile. These are fairly small changes that would be easy to reinstate, even just by - as you say - running the rails generator again to figure out what we're missing.
I'm less certain about #30 - I believe that removing some of those directories can come back to bite us later and it might be worth just leaving them in there?