Skip to content

Ruby 3.x upgrade and version bump to 2.0.0#2

Merged
JPDuchesne merged 6 commits intomasterfrom
jpd/ruby3-upgrade
Feb 21, 2026
Merged

Ruby 3.x upgrade and version bump to 2.0.0#2
JPDuchesne merged 6 commits intomasterfrom
jpd/ruby3-upgrade

Conversation

@JPDuchesne
Copy link
Contributor

@JPDuchesne JPDuchesne commented Feb 21, 2026

Summary

  • Breaking: Drop Ruby 2.x support, require Ruby >= 3.2 (semver major bump to 2.0.0)
  • Update parser (>= 3.0) and unparser (>= 0.6) for Ruby 3.x compatibility
  • Bump ast_transform dependency to ~> 2.0
  • Merge consecutive :str nodes in dstr transformations to satisfy unparser 0.8.x strictness
  • Add .compact to process_rspock to handle nil children from empty class bodies
  • Replace pry-byebug with pry, coveralls with simplecov

CI/CD

  • Replace Travis CI with GitHub Actions (ci.yml: tests on Ruby 3.2–3.3, release.yml: automated gem publish on tag push via Trusted Publishing)
  • Add Codecov integration with SimpleCov JSON formatter
  • Release workflow validates that git tag matches version.rb before publishing

Tests

  • Add test for dstr transformation when last child is not a :str node (covers SPACE_STR_AST append branch)
  • Update test expectations to match unparser 0.8.x output formatting

Docs

  • Update README badges (Travis/Coveralls → GitHub Actions/Codecov)
  • Document release process (GitHub UI and CLI flows)
  • Fix homepage URL in gemspec

Dependencies

Test plan

  • All 129 tests pass locally on Ruby 3.3 (95.41% coverage)
  • CI passes on Ruby 3.2, 3.3 (blocked until ast-transform 2.0.0 is merged)

Setup required after merge

  1. Codecov: Sign in at codecov.io with GitHub, add repo, add upload token as CODECOV_TOKEN secret
  2. Trusted Publishing: Configure gem on rubygems.org as a trusted publisher

JPDuchesne and others added 6 commits February 21, 2026 11:10
- Bump required_ruby_version from ~> 2.5 to >= 3.0
- Upgrade parser from ~> 2.5 to >= 3.0, unparser from ~> 0.4 to >= 0.6
- Replace coveralls/pry-byebug with simplecov/pry (Ruby 3 compat)
- Remove Travis CI version logic from gemspec
- Fix consecutive :str nodes in :dstr for unparser 0.8 round-trip
- Fix nil children in :begin nodes from empty class bodies
- Filter nil children in process_rspock
- Update test expectations for unparser 0.8 output formatting
- Point ast_transform to local path for development

Co-authored-by: Cursor <cursoragent@cursor.com>
- Require Ruby >= 3.0, update parser (>= 3.0) and unparser (>= 0.6)
- Bump ast_transform dependency to ~> 2.0
- Replace Travis CI with GitHub Actions (ci.yml + release.yml with Trusted Publishing)
- Replace Coveralls with SimpleCov + Codecov
- Replace pry-byebug with pry (Ruby 3 compatible)
- Add test for dstr transformation when last child is not a str node
- Fix homepage URL in gemspec
- Update README with new badges and release process documentation

Co-authored-by: Cursor <cursoragent@cursor.com>
Ruby 3.0 is EOL, and unparser 0.8.x + Bundler 2.5.x have compatibility
issues with Ruby 3.0/3.1's RubyGems.

Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
- Remove git source from Gemfile, use published ast_transform ~> 2.0
- Fix release workflow to use gem build/push instead of rake release

Co-authored-by: Cursor <cursoragent@cursor.com>
@JPDuchesne JPDuchesne merged commit 8edca69 into master Feb 21, 2026
2 checks passed
@JPDuchesne JPDuchesne deleted the jpd/ruby3-upgrade branch February 21, 2026 20:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant