From 307cd9c452c936233a04ed6a2a59984e96eac15e Mon Sep 17 00:00:00 2001 From: Sonu Saha Date: Thu, 19 Sep 2024 13:42:12 +0530 Subject: [PATCH] chore: continue support for ruby < 3.0 Signed-off-by: Sonu Saha --- chef-zero.gemspec | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/chef-zero.gemspec b/chef-zero.gemspec index 48ce2d6..5e29a6b 100644 --- a/chef-zero.gemspec +++ b/chef-zero.gemspec @@ -16,7 +16,11 @@ Gem::Specification.new do |s| # Note: 7.1.0 does not defaults its cache_format_version to 7.1 but 6.1 instead which gives deprecation warnings # Remove the version constraint when we can upgrade to 7.1.1 post stable release of Activesupport 7.1 # Similar issue with 7.0 existed: https://github.com/rails/rails/pull/45293 - s.add_dependency "activesupport", "~> 7.0", "< 7.1" + if RUBY_VERSION >= '3.0' + s.add_dependency "activesupport", "~> 7.0", "< 7.1" + else + s.add_dependency "activesupport", "~> 6.1" # Pin for Ruby 2.6 support + end s.add_dependency "mixlib-log", ">= 2.0", "< 4.0" s.add_dependency "hashie", ">= 2.0", "< 5.0" s.add_dependency "uuidtools", "~> 2.1"