c7d782f1ab2488ff0e44c2d72d9b81ea24b3195c

Author
Pablo Cantero <pablo@pablocantero.com>
Committer
Pablo Cantero <pablo@pablocantero.com>
Date

Message

Add the update from @mtwentyman https://github.com/phstc/dotfiles/pull/1
to make it work for older versions of capistrano

Diff

 1diff --git a/plugins/capistrano/_capistrano b/plugins/capistrano/_capistrano
 2index c181b55cac1a13e68552600381f0ff538c80a83b..e6e71ffcc80d121d3adba7bde7f461bafcaa26b3 100644
 3--- a/plugins/capistrano/_capistrano
 4+++ b/plugins/capistrano/_capistrano
 5@@ -14,7 +14,7 @@ _arguments -C \
 6 _cap_tasks() {
 7   if [[ -f config/deploy.rb || -f Capfile ]]; then
 8     if [[ ! -f .cap_tasks~ ]]; then
 9-      shipit -v --tasks | awk '{command=$2; $1=$2=$3=""; gsub(/^[ \t\r\n]+/, "", $0); gsub(":", "\\:", command); print command"["$0"]"}' > .cap_tasks~
10+      shipit -v --tasks | sed 's/\(\[\)\(.*\)\(\]\)/\2:/' | awk '{command=$2; $1=$2=$3=""; gsub(/^[ \t\r\n]+/, "", $0); gsub(":", "\\:", command); print command"["$0"]"}' > .cap_tasks~
11     fi
12 
13     OLD_IFS=$IFS