From 774107b423f57ebfd53038005f9d61a7e0161d95 Mon Sep 17 00:00:00 2001 From: Valter Santos Date: Wed, 16 Oct 2024 14:09:22 +0100 Subject: [PATCH] Rails 7.2 support (#47) * Rails 7.2 support * Drop Rails 6.1 support Update ruby versions to latest maintenance release * Update changelog * Update config.yml ruby version * Update rails versions to latest maintenance release * Fix target ruby version and linting --- .circleci/config.yml | 17 ++++++++--------- .rubocop.yml | 2 +- .ruby-version | 2 +- Appraisals | 18 +++++++++--------- CHANGELOG.md | 5 +++++ .../{rails_6.1.gemfile => rails_7.2.gemfile} | 4 ++-- lib/rails_multitenant/version.rb | 2 +- rails_multitenant.gemspec | 6 +++--- 8 files changed, 30 insertions(+), 26 deletions(-) rename gemfiles/{rails_6.1.gemfile => rails_7.2.gemfile} (59%) diff --git a/.circleci/config.yml b/.circleci/config.yml index 48a443c..cf7b241 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -2,14 +2,14 @@ version: 2.1 jobs: lint: docker: - - image: cimg/ruby:3.0.6 + - image: cimg/ruby:3.1.6 working_directory: ~/rails-multitenant steps: - checkout - restore_cache: keys: - - v1-gems-ruby-3.0.6-{{ checksum "rails_multitenant.gemspec" }}-{{ checksum "Gemfile" }} - - v1-gems-ruby-3.0.6- + - v1-gems-ruby-3.1.6-{{ checksum "rails_multitenant.gemspec" }}-{{ checksum "Gemfile" }} + - v1-gems-ruby-3.1.6- - run: name: Install Gems command: | @@ -18,7 +18,7 @@ jobs: bundle clean fi - save_cache: - key: v1-gems-ruby-3.0.6-{{ checksum "rails_multitenant.gemspec" }}-{{ checksum "Gemfile" }} + key: v1-gems-ruby-3.1.6-{{ checksum "rails_multitenant.gemspec" }}-{{ checksum "Gemfile" }} paths: - "vendor/bundle" - "gemfiles/vendor/bundle" @@ -69,11 +69,10 @@ workflows: matrix: parameters: gemfile: - - gemfiles/rails_6.1.gemfile - gemfiles/rails_7.0.gemfile - gemfiles/rails_7.1.gemfile + - gemfiles/rails_7.2.gemfile ruby_version: - - 3.0.6 - - 3.1.4 - - 3.2.2 - - 3.3.0 + - 3.1.6 + - 3.2.5 + - 3.3.5 diff --git a/.rubocop.yml b/.rubocop.yml index c9258ce..ba292f4 100644 --- a/.rubocop.yml +++ b/.rubocop.yml @@ -2,7 +2,7 @@ inherit_gem: salsify_rubocop: conf/rubocop.yml AllCops: - TargetRubyVersion: 3.0 + TargetRubyVersion: 3.1 Exclude: - 'gemfiles/**/*' - 'vendor/**/*' diff --git a/.ruby-version b/.ruby-version index 1f7da99..15a2799 100644 --- a/.ruby-version +++ b/.ruby-version @@ -1 +1 @@ -2.7.7 +3.3.0 diff --git a/Appraisals b/Appraisals index a2c001a..a09c728 100644 --- a/Appraisals +++ b/Appraisals @@ -1,16 +1,16 @@ # frozen_string_literal: true -appraise 'rails-6.1' do - gem 'activerecord', '~> 6.1.7' - gem 'activesupport', '~> 6.1.7' -end - appraise 'rails-7.0' do - gem 'activerecord', '~> 7.0.4' - gem 'activesupport', '~> 7.0.4' + gem 'activerecord', '~> 7.0.8' + gem 'activesupport', '~> 7.0.8' end appraise 'rails-7.1' do - gem 'activerecord', '~> 7.1.0' - gem 'activesupport', '~> 7.1.0' + gem 'activerecord', '~> 7.1.4' + gem 'activesupport', '~> 7.1.4' +end + +appraise 'rails-7.2' do + gem 'activerecord', '~> 7.2.1' + gem 'activesupport', '~> 7.2.1' end diff --git a/CHANGELOG.md b/CHANGELOG.md index dfdb0d6..631d3dd 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,10 @@ # Changelog +## 0.20.0 +* Rails 7.2 support +* Drop unsupported rails version 6.1 +* Drop unsupported ruby 3.0 + ## 0.19.0 * Rails 7.1 support * Drop unsupported rails versions < 6.1 diff --git a/gemfiles/rails_6.1.gemfile b/gemfiles/rails_7.2.gemfile similarity index 59% rename from gemfiles/rails_6.1.gemfile rename to gemfiles/rails_7.2.gemfile index 767c731..66b3b6d 100644 --- a/gemfiles/rails_6.1.gemfile +++ b/gemfiles/rails_7.2.gemfile @@ -2,7 +2,7 @@ source "https://rubygems.org" -gem "activerecord", "~> 6.1.7" -gem "activesupport", "~> 6.1.7" +gem "activerecord", "~> 7.2.1" +gem "activesupport", "~> 7.2.1" gemspec path: "../" diff --git a/lib/rails_multitenant/version.rb b/lib/rails_multitenant/version.rb index 703c22d..9875f6e 100644 --- a/lib/rails_multitenant/version.rb +++ b/lib/rails_multitenant/version.rb @@ -1,5 +1,5 @@ # frozen_string_literal: true module RailsMultitenant - VERSION = '0.19.0' + VERSION = '0.20.0' end diff --git a/rails_multitenant.gemspec b/rails_multitenant.gemspec index ee4aaf7..f1af19f 100644 --- a/rails_multitenant.gemspec +++ b/rails_multitenant.gemspec @@ -24,10 +24,10 @@ Gem::Specification.new do |spec| spec.files = Dir['lib/**/*.rb', 'LICENSE.txt'] spec.require_paths = ['lib'] - spec.required_ruby_version = '>= 3.0' + spec.required_ruby_version = '>= 3.1' - spec.add_dependency 'activerecord', '>= 6.1', '< 7.2' - spec.add_dependency 'activesupport', '>= 6.1', '< 7.2' + spec.add_dependency 'activerecord', '>= 7.0', '< 7.3' + spec.add_dependency 'activesupport', '>= 7.0', '< 7.3' spec.add_development_dependency 'appraisal' spec.add_development_dependency 'coveralls'