Skip to content

Commit

Permalink
Merge pull request #67 from tungleduyxyz/jruby_9.4_fix_bugs
Browse files Browse the repository at this point in the history
Fix the warbler issue cannot install Gem
  • Loading branch information
pierre authored Dec 17, 2023
2 parents 78e9a19 + f2fc47e commit 330eb4d
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions config/warble.rb
Original file line number Diff line number Diff line change
Expand Up @@ -20,3 +20,21 @@

config.jar_name = 'killbill-admin-ui-standalone'
end

module FixInit
def add_init_file(config)
super
return unless @files[config.init_filename]

contents = @files[config.init_filename].read
add_before = "require 'bundler/shared_helpers'"
line_to_add = "Gem.paths = ENV\n"
@files[config.init_filename] = StringIO.new(contents.gsub(add_before, "#{line_to_add}\\0"))
end
end

module Warbler
class Jar
prepend FixInit
end
end

0 comments on commit 330eb4d

Please sign in to comment.