Skip to content
This repository has been archived by the owner on Sep 1, 2021. It is now read-only.

Commit

Permalink
* replaced hardcoded system commands
Browse files Browse the repository at this point in the history
  • Loading branch information
Sergio Rubio committed Nov 10, 2010
1 parent e747025 commit 382bc98
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions Library/Homebrew/formula_installer.rb
Expand Up @@ -55,16 +55,16 @@ def check_external_deps f
return unless f.external_deps

f.external_deps[:python].each do |dep|
raise pyerr(dep) unless quiet_system "/usr/bin/env", "python", "-c", "import #{dep}"
raise pyerr(dep) unless quiet_system SystemCommand.env, "python", "-c", "import #{dep}"
end
f.external_deps[:perl].each do |dep|
raise plerr(dep) unless quiet_system "/usr/bin/env", "perl", "-e", "use #{dep}"
raise plerr(dep) unless quiet_system SystemCommand.env, "perl", "-e", "use #{dep}"
end
f.external_deps[:ruby].each do |dep|
raise rberr(dep) unless quiet_system "/usr/bin/env", "ruby", "-rubygems", "-e", "require '#{dep}'"
raise rberr(dep) unless quiet_system SystemCommand.env, "ruby", "-rubygems", "-e", "require '#{dep}'"
end
f.external_deps[:jruby].each do |dep|
raise jrberr(dep) unless quiet_system "/usr/bin/env", "jruby", "-rubygems", "-e", "require '#{dep}'"
raise jrberr(dep) unless quiet_system SystemCommand.env, "jruby", "-rubygems", "-e", "require '#{dep}'"
end
end

Expand Down Expand Up @@ -106,7 +106,7 @@ def install_private f
fork do
begin
read.close
exec '/usr/bin/nice', '/usr/bin/ruby', '-I', File.dirname(__FILE__), '-rinstall', f.path, '--', *ARGV.options_only
exec SystemCommand.nice, SystemCommand.ruby, '-I', File.dirname(__FILE__), '-rinstall', f.path, '--', *ARGV.options_only
rescue => e
Marshal.dump(e, write)
write.close
Expand Down

0 comments on commit 382bc98

Please sign in to comment.