diff --git a/lib-injection/host_inject.rb b/lib-injection/host_inject.rb index 8baf5e18293..36677d47357 100644 --- a/lib-injection/host_inject.rb +++ b/lib-injection/host_inject.rb @@ -195,7 +195,7 @@ def bundler_supported? next end - bundle_add_cmd = "bundle add #{gem} --skip-install --version #{gem_version_mapping[gem]} " + bundle_add_cmd = "bundle _#{Bundler::VERSION}_ add #{gem} --skip-install --version #{gem_version_mapping[gem]} " bundle_add_cmd << ' --verbose ' if ENV['DD_TRACE_DEBUG'] == 'true' bundle_add_cmd << '--require datadog/auto_instrument' if gem == 'datadog'