Skip to content

Commit

Permalink
Fix bigdecimal install issue for jruby
Browse files Browse the repository at this point in the history
The latest gem version doesn't have a java stub so it fails to install.
Lock it on the last version that does have one.
  • Loading branch information
tombruijn committed May 7, 2024
1 parent 6cccefc commit f87b568
Show file tree
Hide file tree
Showing 6 changed files with 35 additions and 13 deletions.
4 changes: 4 additions & 0 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,7 @@
source "https://rubygems.org"

gemspec

# Fix install issue for jruby on gem 3.1.8.
# No java stub is published.
gem "bigdecimal", "3.1.7" if RUBY_PLATFORM == "java"
12 changes: 7 additions & 5 deletions gemfiles/no_dependencies.gemfile
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
source 'https://rubygems.org'
source "https://rubygems.org"

ruby_version = Gem::Version.new(RUBY_VERSION)
if ruby_version < Gem::Version.new("2.3.0")
gem 'rack', '~> 1.6'
end
gem "rack", "~> 1.6" if ruby_version < Gem::Version.new("2.3.0")

gemspec :path => '../'
# Fix install issue for jruby on gem 3.1.8.
# No java stub is published.
gem "bigdecimal", "3.1.7" if RUBY_PLATFORM == "java"

gemspec :path => "../"
10 changes: 7 additions & 3 deletions gemfiles/rails-6.0.gemfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
source 'https://rubygems.org'
source "https://rubygems.org"

gem 'rails', '~> 6.0.0'
gem "rails", "~> 6.0.0"
gem "sidekiq"

gemspec :path => '../'
# Fix install issue for jruby on gem 3.1.8.
# No java stub is published.
gem "bigdecimal", "3.1.7" if RUBY_PLATFORM == "java"

gemspec :path => "../"
6 changes: 5 additions & 1 deletion gemfiles/rails-6.1.gemfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
source "https://rubygems.org"

gem "net-smtp", :require => false
gem "rails", "~> 6.1.0"
gem "net-smtp", require: false
gem "sidekiq"

# Fix install issue for jruby on gem 3.1.8.
# No java stub is published.
gem "bigdecimal", "3.1.7" if RUBY_PLATFORM == "java"

gemspec :path => "../"
12 changes: 8 additions & 4 deletions gemfiles/rails-7.0.gemfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
source 'https://rubygems.org'
source "https://rubygems.org"

gem 'rails', "~> 7.0.1"
gem "sidekiq"
gem "rails", "~> 7.0.1"
gem "rake", "> 12.2"
gem "sidekiq"

# Fix install issue for jruby on gem 3.1.8.
# No java stub is published.
gem "bigdecimal", "3.1.7" if RUBY_PLATFORM == "java"

gemspec :path => '../'
gemspec :path => "../"
4 changes: 4 additions & 0 deletions gemfiles/rails-7.1.gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,8 @@ gem "rails", "~> 7.1.0"
gem "rake", "> 12.2"
gem "sidekiq"

# Fix install issue for jruby on gem 3.1.8.
# No java stub is published.
gem "bigdecimal", "3.1.7" if RUBY_PLATFORM == "java"

gemspec :path => "../"

0 comments on commit f87b568

Please sign in to comment.