Skip to content

Commit

Permalink
fix bundle exec for the new, less hacky Thor
Browse files Browse the repository at this point in the history
  • Loading branch information
indirect committed Sep 19, 2011
1 parent 71f989f commit c52eaed
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions lib/bundler/cli.rb
Expand Up @@ -14,7 +14,7 @@ def initialize(*)
Bundler.rubygems.ui = UI::RGProxy.new(Bundler.ui)
end

check_unknown_options!
check_unknown_options! :except => :exec

default_task :install
class_option "no-color", :type => :boolean, :banner => "Disable colorization in output"
Expand Down Expand Up @@ -333,14 +333,14 @@ def package
bundle exec you can require and call the bundled gems as if they were installed
into the systemwide Rubygems repository.
D
def exec(*)
ARGV.shift # remove "exec"
def exec(*args)
args.shift # remove "exec"

Bundler.setup

begin
# Run
Kernel.exec(*ARGV)
Kernel.exec(*args)
rescue Errno::EACCES
Bundler.ui.error "bundler: not executable: #{ARGV.first}"
exit 126
Expand Down

0 comments on commit c52eaed

Please sign in to comment.