diff options
author | Andre Arko <andre@arko.net> | 2015-03-27 01:12:38 -0700 |
---|---|---|
committer | Andre Arko <andre@arko.net> | 2015-03-27 01:41:08 -0700 |
commit | 36314e92ac502674ed2ffc201b2343c8856fa990 (patch) | |
tree | b6c226862a3538a4780f4a2ac7cdd7c8dcf3968b /lib | |
parent | bfbec4ef29d323c8079cb5ec946ccd51cd5b3876 (diff) | |
download | bundler-36314e92ac502674ed2ffc201b2343c8856fa990.tar.gz |
make executables executable, and test them
closes #3517, #3511
Diffstat (limited to 'lib')
-rw-r--r-- | lib/bundler/cli/gem.rb | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/lib/bundler/cli/gem.rb b/lib/bundler/cli/gem.rb index 9ce8de4a..add19ff3 100644 --- a/lib/bundler/cli/gem.rb +++ b/lib/bundler/cli/gem.rb @@ -54,6 +54,11 @@ module Bundler "bin/setup.tt" => "bin/setup" } + executables = %w[ + bin/console + bin/setup + ] + if ask_and_set(:coc, "Do you want to include a code of conduct in gems you generate?", "Codes of conduct can increase contributions to your project by contributors who " \ "prefer collaborative, safe spaces. You can read more about the code of conduct at " \ @@ -105,6 +110,10 @@ module Bundler thor.template("newgem/#{src}", target.join(dst), config) end + executables.each do |path| + FileUtils.chmod "+x", target.join(path).to_s + end + Bundler.ui.info "Initializing git repo in #{target}" Dir.chdir(target) { `git init`; `git add .` } |