forked from chef/chef
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix bundle locking on bundler 1.12 and enforce version we want
- Loading branch information
Showing
3 changed files
with
30 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,19 @@ | ||
#!/usr/bin/env ruby | ||
|
||
platforms = ARGV.shift | ||
platforms = platforms.split(" ").map { |p| Gem::Platform.new(p) } | ||
Gem::Platform.instance_eval { @local = platforms.last } | ||
old_platforms = Gem.platforms | ||
Gem.platforms = platforms.split(" ").map { |p| Gem::Platform.new(p) } | ||
Gem.platforms = platforms | ||
puts "bundle-platform set Gem.platforms to #{Gem.platforms.map { |p| p.to_s }} (was #{old_platforms.map { |p| p.to_s } })" | ||
|
||
desired_version = ARGV.shift.delete("_", "") | ||
|
||
# The rest of this is a normal bundler binstub | ||
require "pathname" | ||
ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../../Gemfile", | ||
Pathname.new(__FILE__).realpath) | ||
|
||
require "rubygems" | ||
|
||
load Gem.bin_path("bundler", "bundle") | ||
load Gem.bin_path("bundler", "bundle", desired_version) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters