diff --git a/plugins/capistrano/_capistrano b/plugins/capistrano/_capistrano index cf6b50c7f..1002dad96 100644 --- a/plugins/capistrano/_capistrano +++ b/plugins/capistrano/_capistrano @@ -1,7 +1,7 @@ #compdef cap #autoload -if [ -f config/deploy.rb ]; then +if [[ -f config/deploy.rb || -f Capfile ]]; then if [[ ! -f .cap_tasks~ || config/deploy.rb -nt .cap_tasks~ ]]; then echo "\nGenerating .cap_tasks~..." > /dev/stderr cap --tasks | grep '#' | cut -d " " -f 2 > .cap_tasks~