lib/ruby_maven.rb in ruby-maven-3.3.12 vs lib/ruby_maven.rb in ruby-maven-3.3.13
- old
+ new
@@ -33,11 +33,17 @@
warn "Polyglot Maven Extension #{version}"
launch( '--version' )
elsif defined? Bundler
# it can be switching from ruby to jruby with invoking maven
# just keep it clean
- Bundler.with_clean_env do
- launch( *args )
+ if Bundler.respond_to?(:with_unbundled_env)
+ Bundler.with_unbundled_env do
+ launch( *args )
+ end
+ else
+ Bundler.with_clean_env do
+ launch( *args )
+ end
end
else
launch( *args )
end
end