Skip to content

Commit

Permalink
Debugging the rubygems upgrade
Browse files Browse the repository at this point in the history
  • Loading branch information
mathieuravaux committed Mar 13, 2013
1 parent f0fe984 commit f1d3f32
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions lib/language_pack/ruby.rb
Expand Up @@ -35,7 +35,7 @@ def self.gem_version(name)
gem_version = nil gem_version = nil
bootstrap_bundler do |bundler_path| bootstrap_bundler do |bundler_path|
$: << "#{bundler_path}/gems/bundler-#{LanguagePack::Ruby::BUNDLER_VERSION}/lib" $: << "#{bundler_path}/gems/bundler-#{LanguagePack::Ruby::BUNDLER_VERSION}/lib"
gem = lockfile_parser.specs.detect {|gem| gem.name == name } gem = lockfile_parser.specs.detect {|g| g.name == name }
gem_version = gem.version if gem gem_version = gem.version if gem
end end


Expand Down Expand Up @@ -216,7 +216,8 @@ def setup_profiled
def update_rubygems def update_rubygems
version = run("gem --version").strip version = run("gem --version").strip
if version < MIN_RUBYGEMS_VERSION if version < MIN_RUBYGEMS_VERSION
command = "env GEM_PATH=#{slug_vendor_base} gem update --system --verbose --backtrace 2>&1" command = "env GEM_HOME=#{slug_vendor_base} PATH=$HOME/bin:$HOME/#{slug_vendor_base}/bin GEM_PATH=#{slug_vendor_base} gem update --system --verbose --backtrace 2>&1"
puts run()
topic "Updating rubygems (#{command})" topic "Updating rubygems (#{command})"
pipe(command) pipe(command)
version = run("gem --version").strip version = run("gem --version").strip
Expand Down Expand Up @@ -362,7 +363,7 @@ def uninstall_binary(path)
# @param [String] tmpdir to store the libyaml files # @param [String] tmpdir to store the libyaml files
def install_libyaml(dir) def install_libyaml(dir)
FileUtils.mkdir_p dir FileUtils.mkdir_p dir
Dir.chdir(dir) do |dir| Dir.chdir(dir) do |d|
run("curl #{VENDOR_URL}/#{LIBYAML_PATH}.tgz -s -o - | tar xzf -") run("curl #{VENDOR_URL}/#{LIBYAML_PATH}.tgz -s -o - | tar xzf -")
end end
end end
Expand Down

0 comments on commit f1d3f32

Please sign in to comment.