nadarei/mina — pull request #43 by tmak (2012-08-10 13:17:18+00:00)
Title: Fix check for arguments in make_run_task lambda

make_run_task = lambda { |name, sample_args|
task name, [:arguments] => :environment do |t, args|
arguments = args[:arguments]
command = send name
unless arguments
puts %{You need to provide arguments. Try: mina "#{name}[#{sample_args}]"}
exit 1
end
queue echo_cmd %[cd "#{deploy_to!}/#{current_path!}" && #{command} #{arguments}]
end
}