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

F/ruby version #25

Open
wants to merge 7 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
49 changes: 24 additions & 25 deletions .rubocop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ AllCops:
- "bin/**/*"
DisplayCopNames: false
StyleGuideCopsOnly: false
TargetRubyVersion: 2.3
TargetRubyVersion: 2.6
Layout/AccessModifierIndentation:
Description: Check indentation of private/protected visibility modifiers.
StyleGuide: https://github.com/bbatsov/ruby-style-guide#indent-public-private-protected
Expand Down Expand Up @@ -146,11 +146,7 @@ Style/Encoding:
Description: Use UTF-8 as the source file encoding.
StyleGuide: https://github.com/bbatsov/ruby-style-guide#utf-8
Enabled: false
EnforcedStyle: always
SupportedStyles:
- when_needed
- always
Style/FileName:
Naming/FileName:
Description: Use snake_case for source file names.
StyleGuide: https://github.com/bbatsov/ruby-style-guide#snake-case-files
Enabled: false
Expand Down Expand Up @@ -205,7 +201,6 @@ Style/IfUnlessModifier:
Description: Favor modifier if/unless usage when you have a single-line body.
StyleGuide: https://github.com/bbatsov/ruby-style-guide#if-as-a-modifier
Enabled: false
MaxLineLength: 80
Layout/IndentationWidth:
Description: Use 2 spaces for indentation.
StyleGuide: https://github.com/bbatsov/ruby-style-guide#spaces-indentation
Expand Down Expand Up @@ -248,7 +243,7 @@ Style/MethodDefParentheses:
SupportedStyles:
- require_parentheses
- require_no_parentheses
Style/MethodName:
Naming/MethodName:
Description: Use the configured style when naming methods.
StyleGuide: https://github.com/bbatsov/ruby-style-guide#snake-case-symbols-methods-vars
Enabled: true
Expand Down Expand Up @@ -297,7 +292,7 @@ Style/PercentQLiterals:
SupportedStyles:
- lower_case_q
- upper_case_q
Style/PredicateName:
Naming/PredicateName:
Description: Check the names of predicate methods.
StyleGuide: https://github.com/bbatsov/ruby-style-guide#bool-methods-qmark
Enabled: true
Expand Down Expand Up @@ -426,7 +421,7 @@ Style/TrailingCommaInArguments:
Description: Checks for trailing comma in argument lists.
StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-trailing-array-commas
Enabled: true
Style/TrailingCommaInLiteral:
Style/TrailingCommaInArrayLiteral:
Description: Checks for trailing comma in array and hash literals.
StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-trailing-array-commas
Enabled: true
Expand Down Expand Up @@ -455,7 +450,7 @@ Style/TrivialAccessors:
- to_str
- to_s
- to_sym
Style/VariableName:
Naming/VariableName:
Description: Use the configured style when naming variables.
StyleGuide: https://github.com/bbatsov/ruby-style-guide#snake-case-symbols-methods-vars
Enabled: true
Expand All @@ -467,7 +462,6 @@ Style/WhileUntilModifier:
Description: Favor modifier while/until usage when you have a single-line body.
StyleGuide: https://github.com/bbatsov/ruby-style-guide#while-as-a-modifier
Enabled: false
MaxLineLength: 80
Style/WordArray:
Description: Use %w or %W for arrays of words.
StyleGuide: https://github.com/bbatsov/ruby-style-guide#percent-w
Expand Down Expand Up @@ -527,20 +521,29 @@ Lint/AssignmentInCondition:
StyleGuide: https://github.com/bbatsov/ruby-style-guide#safe-assignment-in-condition
Enabled: false
AllowSafeAssignment: true
Lint/EndAlignment:
Layout/EndAlignment:
Description: Align ends correctly.
Enabled: true
EnforcedStyleAlignWith: keyword
SupportedStylesAlignWith:
- keyword
- variable
Lint/DefEndAlignment:
Layout/DefEndAlignment:
Description: Align ends corresponding to defs correctly.
Enabled: true
EnforcedStyleAlignWith: start_of_line
SupportedStylesAlignWith:
- start_of_line
- def
Metrics/LineLength:
Description: Limit lines to 100 characters.
StyleGuide: https://github.com/bbatsov/ruby-style-guide#100-character-limits
Enabled: true
Max: 100
AllowURI: true
URISchemes:
- http
- https
Rails/ActionFilter:
Description: Enforces consistent use of action filter methods.
Enabled: true
Expand Down Expand Up @@ -592,7 +595,7 @@ Style/SymbolArray:
Layout/ExtraSpacing:
Description: Do not use unnecessary spacing.
Enabled: false
Style/AccessorMethodName:
Naming/AccessorMethodName:
Description: Check the naming of accessor methods for get_/set_.
Enabled: false
Style/Alias:
Expand All @@ -611,7 +614,7 @@ Style/AsciiComments:
Description: Use only ascii symbols in comments.
StyleGuide: https://github.com/bbatsov/ruby-style-guide#english-comments
Enabled: false
Style/AsciiIdentifiers:
Naming/AsciiIdentifiers:
Description: Use only ascii symbols in identifiers.
StyleGuide: https://github.com/bbatsov/ruby-style-guide#english-identifiers
Enabled: false
Expand Down Expand Up @@ -657,7 +660,7 @@ Style/ColonMethodCall:
Layout/CommentIndentation:
Description: Indentation of comments.
Enabled: true
Style/ConstantName:
Naming/ConstantName:
Description: Constants should use SCREAMING_SNAKE_CASE.
StyleGuide: https://github.com/bbatsov/ruby-style-guide#screaming-snake-case
Enabled: true
Expand Down Expand Up @@ -710,7 +713,7 @@ Style/EvenOdd:
Description: Favor the use of Fixnum#even? && Fixnum#odd?
StyleGuide: https://github.com/bbatsov/ruby-style-guide#predicate-methods
Enabled: false
Style/FlipFlop:
Lint/FlipFlop:
Description: Checks for flip flops
StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-flip-flops
Enabled: false
Expand Down Expand Up @@ -787,7 +790,7 @@ Style/OneLineConditional:
Description: Favor the ternary operator(?:) over if/then/else/end constructs.
StyleGuide: https://github.com/bbatsov/ruby-style-guide#ternary-operator
Enabled: false
Style/OpMethod:
Naming/BinaryOperatorParameterName:
Description: When defining binary operators, name the argument other.
StyleGuide: https://github.com/bbatsov/ruby-style-guide#other-arg
Enabled: false
Expand Down Expand Up @@ -922,10 +925,10 @@ Lint/AmbiguousRegexpLiteral:
Description: Checks for ambiguous regexp literals in the first argument of a method
invocation without parenthesis.
Enabled: false
Lint/BlockAlignment:
Layout/BlockAlignment:
Description: Align block ends correctly.
Enabled: true
Lint/ConditionPosition:
Layout/ConditionPosition:
Description: Checks for condition placed in a confusing position relative to the
keyword.
StyleGuide: https://github.com/bbatsov/ruby-style-guide#same-line-condition
Expand Down Expand Up @@ -962,10 +965,6 @@ Lint/HandleExceptions:
Description: Don't suppress exception.
StyleGuide: https://github.com/bbatsov/ruby-style-guide#dont-hide-exceptions
Enabled: false
Lint/InvalidCharacterLiteral:
Description: Checks for invalid character literals with a non-escaped whitespace
character.
Enabled: false
Lint/LiteralInCondition:
Description: Checks of literals used in conditions.
Enabled: false
Expand Down
2 changes: 1 addition & 1 deletion .ruby-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
2.3
2.6
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
language: ruby
rvm:
- 2.3.1
- 2.6.6
script:
- cd spec/dummy && RAILS_ENV=test bundle exec rake db:create db:migrate
- cd ../.. && bundle exec rspec spec
Expand Down
Loading