bin/screwcap in screwcap-0.6.pre vs bin/screwcap in screwcap-0.6.pre2

- old
+ new

@@ -27,17 +27,18 @@ if opts[:debug] == true require 'ruby-debug' Debugger.start end - if opts[:tasks] == true + if opts[:tasks] == true or ARGV.size == 1 recipe_file = ARGV.shift deployer = TaskManager.new(opts.merge(:recipe_file => recipe_file)) - $stdout << "Tasks Available:\n" if deployer.__tasks.size > 0 + $stdout << "\nTasks Available:\n" if deployer.__tasks.size > 0 deployer.__tasks.map {|t| t.__name }.each {|name| $stdout << " #{name}\n" } - $stdout << "Sequences Available:\n" if deployer.__sequences.size > 0 + $stdout << "\nSequences Available:\n" if deployer.__sequences.size > 0 deployer.__sequences.map {|t| t.__name }.each {|name| $stdout << " #{name}\n" } + $stdout << "\n" exit end if opts[:dry_run] == true recipe_file = ARGV.shift @@ -61,10 +62,9 @@ $stdout << "To see what recipes you can run, type 'rake -T remote'.\n" $stdout << "Please visit http://gammons.github.com/screwcap for help.\n" exit end - raise Trollop::HelpNeeded if ARGV.size < 2 recipe_file = ARGV.shift begin TaskManager.new(opts.merge(:recipe_file => recipe_file)).run! ARGV.map {|a| a.to_sym } rescue Exception => e raise e if opts[:debug] == true