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

Update Rails 7.2 #744

Open
wants to merge 20 commits into
base: main
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
3 changes: 0 additions & 3 deletions .bundle/config

This file was deleted.

1 change: 0 additions & 1 deletion .envrc

This file was deleted.

2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ jobs:
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: 3.0.3
ruby-version: 3.3

- name: Setup config
run: |
Expand Down
8 changes: 8 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -65,3 +65,11 @@ config/settings.yml
/esdata
/rvm-installer
/.vscode

/.bundle/config
/.envrc
/vendor/cache
/contrib
/Session.vim
/.bundle
/.solargraph.yml
63 changes: 56 additions & 7 deletions .rubocop.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,29 @@
inherit_from: .rubocop_todo.yml

AllCops:
TargetRubyVersion: 2.5
TargetRubyVersion: 3.1
Exclude:
# Exclude generated files from Rails
- bin/rails
- bin/rake
- bin/setup
- config/application.rb
- config/boot.rb
- config/environment.rb
- config/environments/development.rb
- config/environments/production.rb
- config/environments/test.rb
- config/initializers/assets.rb
- config/initializers/content_security_policy.rb
- config/initializers/cors.rb
- config/initializers/filter_parameter_logging.rb
- config/initializers/inflections.rb
- config/initializers/permissions_policy.rb
# Exclude others
- Vagrantfile
- tmp/**/*
- contrib/**/*
- db/schema.rb

# loading order actually matters
Bundler/OrderedGems:
Expand Down Expand Up @@ -27,9 +51,9 @@ Style/Not:
#Style/RedundantSelf:
# Enabled: false

# Good cop, but to spammy
#Style/StringLiterals:
#Enabled: false
# I give up, the readability/security benefit is too small. Just use whatever quotes.
Style/StringLiterals:
Enabled: false

# use { only for single line blocks, but allow block content on its own line to keep line length short
# each { |l|
Expand All @@ -51,6 +75,9 @@ Layout/ParameterAlignment:
Enabled: true
EnforcedStyle: with_fixed_indentation

Layout/MultilineMethodCallIndentation:
Enabled: false

# Do not write 1234 as 1_234
Style/NumericLiterals:
Enabled: false
Expand All @@ -59,6 +86,9 @@ Style/NumericLiterals:
Metrics/AbcSize:
Max: 40

Metrics/MethodLength:
Max: 40

# too spammy
Style/Documentation:
Enabled: false
Expand All @@ -67,12 +97,31 @@ Layout/HashAlignment:
Enabled: false

# adapt rubocop to existing code "style"
Layout/EmptyLineAfterGuardClause:
Enabled: false
Style/IfUnlessModifier:
Enabled: false
Style/NumericPredicate:
Enabled: false
Style/RedundantReturn:
Enabled: false

Style/StringConcatenation:
Enabled: false
Style/ExpandPathArguments:
Enabled: false
Style/PercentLiteralDelimiters:
Enabled: false
Style/SymbolArray:
Enabled: false
Style/WordArray:
Enabled: false
Layout/ArrayAlignment:
Enabled: false
Style/RegexpLiteral:
Enabled: false
Layout/ArgumentAlignment:
Enabled: false
Layout/CommentIndentation:
Enabled: false
Style/NumericLiteralPrefix:
Enabled: false
Layout/LeadingCommentSpace:
Enabled: false
Loading
Loading