11# frozen_string_literal: true 
22
3- source  ' https://rubygems.org' 
3+ source  " https://rubygems.org" 
44git_source ( :github )  {  |repo | "https://github.com/#{ repo }   } 
55
6- branch  =  ENV . fetch ( 'SOLIDUS_BRANCH' ,  'main' ) 
7- solidus_git ,  solidus_frontend_git  =  if  ( branch  == 'main' )  || ( branch  >= 'v3.2' ) 
8-                                       %w[ solidusio/solidus  solidusio/solidus_frontend ] 
9-                                     else 
10-                                       %w[ solidusio/solidus ]  * 2 
11-                                     end 
12- gem  'solidus' ,  github : solidus_git ,  branch : branch 
13- gem  'solidus_frontend' ,  github : solidus_frontend_git ,  branch : branch 
6+ branch  =  ENV . fetch ( "SOLIDUS_BRANCH" ,  "main" ) 
147
15- # Needed to help Bundler figure out how to resolve dependencies, 
16- # otherwise it takes forever to resolve them. 
17- # See https://github.com/bundler/bundler/issues/6677 
18- gem  'rails' ,  '>0.a' 
8+ gem  "solidus" ,  github : "solidusio/solidus" ,  branch : branch 
9+ 
10+ # The `solidus_frontend` gem is deprecated and isn't expected to have major 
11+ # version updates after v3.2. 
12+ if  branch  >= "v3.2" 
13+   gem  "solidus_frontend" 
14+ elsif  branch  == "main" 
15+   gem  "solidus_frontend" ,  github : "solidusio/solidus_frontend" ,  branch : branch 
16+ else 
17+   gem  "solidus_frontend" ,  github : "solidusio/solidus" ,  branch : branch 
18+ end 
19+ 
20+ rails_requirement_string  =  ENV . fetch ( "RAILS_VERSION" ,  "~> 8.0" ) 
21+ gem  "rails" ,  rails_requirement_string 
22+ 
23+ gem  "state_machines" ,  "0.6.0" 
1924
2025# Provides basic authentication functionality for testing parts of your engine 
21- gem  ' solidus_auth_devise' 
26+ gem  " solidus_auth_devise" 
2227
23- case  ENV [ 'DB' ] 
24- when  ' mysql' 
25-   gem  ' mysql2' 
26- when  ' postgresql' 
27-   gem  'pg' 
28+ case  ENV [ "DB" ] 
29+ when  " mysql" 
30+   gem  " mysql2" 
31+ when  " postgresql" 
32+   gem  "pg" 
2833else 
29-   gem  'sqlite3' 
34+   rails_version  =  Gem ::Requirement . new ( rails_requirement_string ) . requirements [ 0 ] [ 1 ] 
35+   sqlite_version  =  ( rails_version  < Gem ::Version . new ( 7.2 ) )  ? "~> 1.4"  : "~> 2.0" 
36+ 
37+   gem  "sqlite3" ,  sqlite_version 
3038end 
3139
3240gemspec 
@@ -36,4 +44,4 @@ gemspec
3644# 
3745# We use `send` instead of calling `eval_gemfile` to work around an issue with 
3846# how Dependabot parses projects: https://github.com/dependabot/dependabot-core/issues/1658. 
39- send ( :eval_gemfile ,  ' Gemfile-local' )  if  File . exist?  ' Gemfile-local' 
47+ send ( :eval_gemfile ,  " Gemfile-local" )  if  File . exist?  " Gemfile-local" 
0 commit comments