diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 1c25f2d..dc1328b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -15,7 +15,7 @@ jobs: - '3.3' - '3.2' - '3.1' - - '3.0' + - 'head' steps: - name: Checkout @@ -30,14 +30,15 @@ jobs: uses: ruby/setup-ruby@v1 with: ruby-version: ${{ matrix.ruby }} - bundler-cache: true - cache-version: 1 + + - name: Bundle install + run: bundle install - name: Fake screen run: Xvfb :99 & - name: RSpec & publish code coverage - uses: paambaati/codeclimate-action@v3.2.0 + uses: paambaati/codeclimate-action@v8.0.0 env: CC_TEST_REPORTER_ID: ${{ secrets.CC_TEST_REPORTER_ID }} DISPLAY: ':99' diff --git a/.tool-versions b/.tool-versions index d554c9c..05668b7 100644 --- a/.tool-versions +++ b/.tool-versions @@ -1 +1 @@ -ruby 3.3.3 +ruby 3.3.4 diff --git a/Gemfile b/Gemfile index 7f4f5e9..c2ac232 100644 --- a/Gemfile +++ b/Gemfile @@ -3,3 +3,12 @@ source 'https://rubygems.org' gemspec + +gem 'factory_bot' +gem 'pry' +gem 'rake' +gem 'rspec' +gem 'rubocop' +gem 'rubocop-rake' +gem 'rubocop-rspec' +gem 'simplecov' diff --git a/Gemfile.lock b/Gemfile.lock index d2a7ad0..c89f28f 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -2,29 +2,29 @@ PATH remote: . specs: ssh-tunnel (1.0.0) - activemodel (>= 5.2) - activesupport (>= 5.2) + activemodel (>= 7.0) + activesupport (>= 7.0) gtk3 i18n - ruby2_keywords subprocess zeitwerk GEM remote: https://rubygems.org/ specs: - activemodel (7.1.3.4) - activesupport (= 7.1.3.4) - activesupport (7.1.3.4) + activemodel (7.2.1) + activesupport (= 7.2.1) + activesupport (7.2.1) base64 bigdecimal - concurrent-ruby (~> 1.0, >= 1.0.2) + concurrent-ruby (~> 1.0, >= 1.3.1) connection_pool (>= 2.2.5) drb i18n (>= 1.6, < 2) + logger (>= 1.4.2) minitest (>= 5.1) - mutex_m - tzinfo (~> 2.0) + securerandom (>= 0.3) + tzinfo (~> 2.0, >= 2.0.5) ast (2.4.2) atk (4.2.2) glib2 (= 4.2.2) @@ -38,10 +38,10 @@ GEM cairo (>= 1.16.2) glib2 (= 4.2.2) coderay (1.1.3) - concurrent-ruby (1.3.3) + concurrent-ruby (1.3.4) connection_pool (2.4.1) diff-lcs (1.5.1) - docile (1.4.0) + docile (1.4.1) drb (2.2.1) factory_bot (6.4.6) activesupport (>= 5.0.0) @@ -67,30 +67,30 @@ GEM concurrent-ruby (~> 1.0) json (2.7.2) language_server-protocol (3.17.0.3) + logger (1.6.0) matrix (0.4.2) method_source (1.1.0) - minitest (5.24.1) - mutex_m (0.2.0) + minitest (5.25.1) native-package-installer (1.1.9) pango (4.2.2) cairo-gobject (= 4.2.2) gobject-introspection (= 4.2.2) - parallel (1.25.1) - parser (3.3.3.0) + parallel (1.26.3) + parser (3.3.4.2) ast (~> 2.4.1) racc pkg-config (1.5.6) pry (0.14.2) coderay (~> 1.1) method_source (~> 1.0) - racc (1.8.0) + racc (1.8.1) rainbow (3.1.1) rake (13.2.1) red-colors (0.4.0) json matrix regexp_parser (2.9.2) - rexml (3.3.1) + rexml (3.3.6) strscan rspec (3.13.0) rspec-core (~> 3.13.0) @@ -98,32 +98,32 @@ GEM rspec-mocks (~> 3.13.0) rspec-core (3.13.0) rspec-support (~> 3.13.0) - rspec-expectations (3.13.1) + rspec-expectations (3.13.2) diff-lcs (>= 1.2.0, < 2.0) rspec-support (~> 3.13.0) rspec-mocks (3.13.1) diff-lcs (>= 1.2.0, < 2.0) rspec-support (~> 3.13.0) rspec-support (3.13.1) - rubocop (1.64.1) + rubocop (1.65.1) json (~> 2.3) language_server-protocol (>= 3.17.0) parallel (~> 1.10) parser (>= 3.3.0.2) rainbow (>= 2.2.2, < 4.0) - regexp_parser (>= 1.8, < 3.0) + regexp_parser (>= 2.4, < 3.0) rexml (>= 3.2.5, < 4.0) rubocop-ast (>= 1.31.1, < 2.0) ruby-progressbar (~> 1.7) unicode-display_width (>= 2.4.0, < 3.0) - rubocop-ast (1.31.3) + rubocop-ast (1.32.1) parser (>= 3.3.1.0) rubocop-rake (0.6.0) rubocop (~> 1.0) - rubocop-rspec (3.0.1) + rubocop-rspec (3.0.4) rubocop (~> 1.61) ruby-progressbar (1.13.0) - ruby2_keywords (0.0.5) + securerandom (0.3.1) simplecov (0.22.0) docile (~> 1.1) simplecov-html (~> 0.11) @@ -135,11 +135,11 @@ GEM tzinfo (2.0.6) concurrent-ruby (~> 1.0) unicode-display_width (2.5.0) - zeitwerk (2.6.16) + zeitwerk (2.6.17) PLATFORMS + arm64-darwin-23 ruby - x86_64-linux DEPENDENCIES factory_bot @@ -153,4 +153,4 @@ DEPENDENCIES ssh-tunnel! BUNDLED WITH - 2.5.14 + 2.5.18 diff --git a/lib/ssh-tunnel.rb b/lib/ssh-tunnel.rb index 3502c6d..c4bc7f4 100644 --- a/lib/ssh-tunnel.rb +++ b/lib/ssh-tunnel.rb @@ -31,7 +31,6 @@ require 'active_support/concern' require 'active_support/core_ext/hash' require 'active_support/core_ext/string' -require 'ruby2_keywords' require 'zeitwerk' loader = Zeitwerk::Loader.for_gem diff --git a/lib/ssh-tunnel/ui/helpers/common/translation_helper.rb b/lib/ssh-tunnel/ui/helpers/common/translation_helper.rb index 301323b..2ffe354 100644 --- a/lib/ssh-tunnel/ui/helpers/common/translation_helper.rb +++ b/lib/ssh-tunnel/ui/helpers/common/translation_helper.rb @@ -7,8 +7,8 @@ module Common module TranslationHelper extend ActiveSupport::Concern - ruby2_keywords def t(*args) - I18n.t(*args) + def t(...) + I18n.t(...) end end diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index 246b28b..5ebe617 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -1,5 +1,8 @@ require 'simplecov' require 'rspec' + +# fix for https://github.com/thoughtbot/factory_bot/issues/1690 +require 'active_support/inflector' require 'factory_bot' # Start Simplecov diff --git a/ssh-tunnel.gemspec b/ssh-tunnel.gemspec index e443954..282d222 100644 --- a/ssh-tunnel.gemspec +++ b/ssh-tunnel.gemspec @@ -19,20 +19,10 @@ Gem::Specification.new do |s| s.bindir = 'exe' s.executables = ['ssh-tunnel'] - s.add_runtime_dependency 'activemodel', '>= 5.2' - s.add_runtime_dependency 'activesupport', '>= 5.2' - s.add_runtime_dependency 'gtk3' - s.add_runtime_dependency 'i18n' - s.add_runtime_dependency 'ruby2_keywords' - s.add_runtime_dependency 'subprocess' - s.add_runtime_dependency 'zeitwerk' - - s.add_development_dependency 'factory_bot' - s.add_development_dependency 'pry' - s.add_development_dependency 'rake' - s.add_development_dependency 'rspec' - s.add_development_dependency 'rubocop' - s.add_development_dependency 'rubocop-rake' - s.add_development_dependency 'rubocop-rspec' - s.add_development_dependency 'simplecov' + s.add_dependency 'activemodel', '>= 7.0' + s.add_dependency 'activesupport', '>= 7.0' + s.add_dependency 'gtk3' + s.add_dependency 'i18n' + s.add_dependency 'subprocess' + s.add_dependency 'zeitwerk' end