Skip to content

Commit d7ba8c3

Browse files
authored
Update Ruby to version 3.1.0 (#589)
Needed to fix an issue with keyword arguments in app.rb Co-authored-by: depfu[bot] <23717796+depfu[bot]@users.noreply.github.com>
1 parent 32a6043 commit d7ba8c3

File tree

6 files changed

+19
-24
lines changed

6 files changed

+19
-24
lines changed

.circleci/config.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ jobs:
88
build:
99
parallelism: 1
1010
docker:
11-
- image: cimg/ruby:2.7.5-browsers
11+
- image: cimg/ruby:3.1.0-browsers
1212
environment:
1313
BUNDLE_JOBS: 3
1414
BUNDLE_RETRY: 3

.rubocop_todo.yml

Lines changed: 13 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# This configuration was generated by
22
# `rubocop --auto-gen-config --auto-gen-only-exclude`
3-
# on 2022-01-15 20:13:59 UTC using RuboCop version 1.23.0.
3+
# on 2022-01-22 20:24:27 UTC using RuboCop version 1.24.1.
44
# The point is for the user to remove these configuration records
55
# one by one as the offenses are removed from the code base.
66
# Note that changes in the inspected code, or installation of new
@@ -81,7 +81,7 @@ Lint/AmbiguousOperatorPrecedence:
8181
- 'spec/factories/feed_factory.rb'
8282
- 'spec/factories/group_factory.rb'
8383

84-
# Offense count: 754
84+
# Offense count: 761
8585
# Configuration parameters: Only, Ignore.
8686
Lint/ConstantResolution:
8787
Enabled: false
@@ -391,7 +391,7 @@ Rails/HttpPositionalArguments:
391391
- 'spec/fever_api_spec.rb'
392392

393393
# Offense count: 1
394-
# Configuration parameters: Include.
394+
# Configuration parameters: IgnoreScopes, Include.
395395
# Include: app/models/**/*.rb
396396
Rails/InverseOf:
397397
Exclude:
@@ -414,7 +414,7 @@ Rails/RakeEnvironment:
414414

415415
# Offense count: 5
416416
# Configuration parameters: Include.
417-
# Include: db/migrate/*.rb
417+
# Include: db/**/*.rb
418418
Rails/ReversibleMigrationMethodDefinition:
419419
Exclude:
420420
- 'db/migrate/20130423001740_drop_email_from_user.rb'
@@ -528,31 +528,26 @@ Style/DocumentationMethod:
528528
Style/FrozenStringLiteralComment:
529529
Enabled: false
530530

531+
# Offense count: 84
532+
# Cop supports --auto-correct.
533+
# Configuration parameters: EnforcedShorthandSyntax, UseHashRocketsWithSymbolValues, PreferHashRocketsForNonAlnumEndingSymbols.
534+
# SupportedStyles: ruby19, hash_rockets, no_mixed_keys, ruby19_no_mixed_keys
535+
# SupportedShorthandSyntax: always, never
536+
Style/HashSyntax:
537+
Enabled: false
538+
531539
# Offense count: 1
532540
Style/InlineComment:
533541
Exclude:
534542
- 'app/utils/opml_parser.rb'
535543

536-
# Offense count: 699
544+
# Offense count: 700
537545
# Cop supports --auto-correct.
538546
# Configuration parameters: IgnoreMacros, IgnoredMethods, IgnoredPatterns, IncludedMacros, AllowParenthesesInMultilineCall, AllowParenthesesInChaining, AllowParenthesesInCamelCaseMethod, AllowParenthesesInStringInterpolation, EnforcedStyle.
539547
# SupportedStyles: require_parentheses, omit_parentheses
540548
Style/MethodCallWithArgsParentheses:
541549
Enabled: false
542550

543-
# Offense count: 8
544-
# Configuration parameters: EnforcedStyle.
545-
# SupportedStyles: if, case, both
546-
Style/MissingElse:
547-
Exclude:
548-
- 'Rakefile'
549-
- 'app.rb'
550-
- 'app/commands/stories/mark_group_as_read.rb'
551-
- 'app/fever_api/write_mark_item.rb'
552-
- 'app/helpers/url_helpers.rb'
553-
- 'app/repositories/story_repository.rb'
554-
- 'spec/support/coverage.rb'
555-
556551
# Offense count: 1
557552
# Cop supports --auto-correct.
558553
# Configuration parameters: EnforcedStyle, IgnoredMethods.

.ruby-version

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
2.7.5
1+
3.1.0

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM ruby:2.7.5
1+
FROM ruby:3.1.0
22

33
ENV RACK_ENV=production
44
ENV PORT=8080

Gemfile.lock

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -244,7 +244,7 @@ DEPENDENCIES
244244
will_paginate
245245

246246
RUBY VERSION
247-
ruby 2.7.5
247+
ruby 3.1.0
248248

249249
BUNDLED WITH
250250
2.2.33

app.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -56,8 +56,8 @@ def render_js(name, locals = {})
5656
erb "js/#{name}.js".to_sym, layout: false, locals: locals
5757
end
5858

59-
def t(*args)
60-
I18n.t(*args)
59+
def t(*args, **kwargs)
60+
I18n.t(*args, **kwargs)
6161
end
6262
end
6363

0 commit comments

Comments
 (0)