From c5f5498750cf210f0c62b391ca279301608b3dc7 Mon Sep 17 00:00:00 2001 From: Faisal N Jawdat Date: Fri, 28 Mar 2025 12:17:19 +0000 Subject: [PATCH 1/2] Remove support for Ruby 3.1 - rubycritic.gemspec: update minimum Ruby version to 3.2 - .rubocop.yml: update target Ruby version to 3.2 - CI: drop Ruby 3.1, and change jruby from 9.4 (Ruby 3.1) to HEAD (Ruby 3.4, still in testing) --- .github/workflows/main.yml | 16 ++++++++-------- .rubocop.yml | 2 +- CHANGELOG.md | 1 + rubycritic.gemspec | 2 +- 4 files changed, 11 insertions(+), 10 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index c3cb3b58..991b2415 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -29,7 +29,6 @@ jobs: fail-fast: false matrix: ruby-version: - - '3.1' - '3.2' - '3.3' - '3.4' @@ -37,8 +36,9 @@ jobs: include: - ruby-version: 'ruby-head' experimental: true - - ruby-version: 'jruby-9.4' + - ruby-version: 'jruby-10' experimental: true + continue-on-error: true steps: - uses: actions/checkout@v4 - name: Set up Ruby ${{ matrix.ruby-version }} @@ -59,7 +59,6 @@ jobs: fail-fast: false matrix: ruby-version: - - '3.1' - '3.2' - '3.3' - '3.4' @@ -67,8 +66,9 @@ jobs: include: - ruby-version: 'ruby-head' experimental: true - - ruby-version: 'jruby-9.4' + - ruby-version: 'jruby-10' experimental: true + continue-on-error: true steps: - uses: actions/checkout@v4 - name: Set up Ruby ${{ matrix.ruby-version }} @@ -89,7 +89,6 @@ jobs: fail-fast: false matrix: ruby-version: - - '3.1' - '3.2' - '3.3' - '3.4' @@ -97,8 +96,9 @@ jobs: include: - ruby-version: 'ruby-head' experimental: true - - ruby-version: 'jruby-9.4' + - ruby-version: 'jruby-10' experimental: true + continue-on-error: true steps: - uses: actions/checkout@v4 - name: Set up Ruby ${{ matrix.ruby-version }} @@ -119,7 +119,6 @@ jobs: fail-fast: false matrix: ruby-version: - - '3.1' - '3.2' - '3.3' - '3.4' @@ -127,8 +126,9 @@ jobs: include: - ruby-version: 'ruby-head' experimental: true - - ruby-version: 'jruby-9.4' + - ruby-version: 'jruby-10' experimental: true + continue-on-error: true steps: - uses: actions/checkout@v4 diff --git a/.rubocop.yml b/.rubocop.yml index 1928c2f7..697d43a6 100644 --- a/.rubocop.yml +++ b/.rubocop.yml @@ -11,7 +11,7 @@ AllCops: - 'tmp/**/*' - 'vendor/**/*' - 'gemfiles/*' - TargetRubyVersion: 3.1 + TargetRubyVersion: 3.2 Metrics/BlockLength: Enabled: false diff --git a/CHANGELOG.md b/CHANGELOG.md index 04bb6e9f..1c4719a2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,6 @@ # main [(unreleased)](https://github.com/whitesmith/rubycritic/compare/v4.9.2...main) +* [CHANGE] Drop support for Ruby 3.1.x, including moving CI from JRuby 9.4 to JRuby 10 (by [@faisal][]) * [CHANGE] Bump aruba, byebug, cucumber, fakefs, rake, reek dependencies (by [@faisal][]) * [BUGFIX] Work around issue preventing feature execution on Ruby 3.5.0dev (by [@faisal][]) * [CHANGE] Add changes or suppress warnings for issues found by newer rubocop (by [@faisal][]) diff --git a/rubycritic.gemspec b/rubycritic.gemspec index 666215a9..8449148f 100644 --- a/rubycritic.gemspec +++ b/rubycritic.gemspec @@ -14,7 +14,7 @@ Gem::Specification.new do |spec| spec.summary = 'RubyCritic is a Ruby code quality reporter' spec.homepage = 'https://github.com/whitesmith/rubycritic' spec.license = 'MIT' - spec.required_ruby_version = '>= 3.1.0' + spec.required_ruby_version = '>= 3.2.0' spec.files = [ 'CHANGELOG.md', From 0ae40fc45d5674f2c3b354592753539dbe9f9c3a Mon Sep 17 00:00:00 2001 From: Ernesto Tagwerker Date: Thu, 6 Mar 2025 16:34:19 -0500 Subject: [PATCH 2/2] add platform value to the gemspec, and require jar-dependencies version --- rubycritic.gemspec | 2 ++ 1 file changed, 2 insertions(+) diff --git a/rubycritic.gemspec b/rubycritic.gemspec index 8449148f..ccab0050 100644 --- a/rubycritic.gemspec +++ b/rubycritic.gemspec @@ -7,6 +7,7 @@ require 'rubycritic/version' Gem::Specification.new do |spec| spec.name = 'rubycritic' spec.version = RubyCritic::VERSION + spec.platform = RUBY_PLATFORM == 'java' ? Gem::Platform::JAVA : Gem::Platform::RUBY spec.authors = ['Guilherme Simoes'] spec.email = ['guilherme.rdems@gmail.com'] spec.description = 'RubyCritic is a tool that wraps around various static analysis gems ' \ @@ -45,6 +46,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'aruba', '~> 2.3.1', '>= 2.3.1' spec.add_development_dependency 'bundler', '>= 2.0.0' if RUBY_PLATFORM == 'java' + spec.add_development_dependency 'jar-dependencies', '~> 0.5.4' spec.add_development_dependency 'pry-debugger-jruby' else spec.add_development_dependency 'byebug', '~> 12.0', '>= 10.0'