libexec/unlock in alpha_omega-0.0.210 vs libexec/unlock in alpha_omega-0.0.212
- old
+ new
@@ -1,18 +1,17 @@
#!/bin/bash -e
-export LOCAL_ONLY=true
+export LOCAL_ONLY=
case "$(basename $0)" in
invoke)
export COMMAND="$1"; shift
if [[ -n $1 ]]; then
set -- $(for a in "$@"; do echo $a.app; done)
fi
- LOCAL_ONLY=
tmp_invoke=$(mktemp -t XXXXXXXXX)
bundle exec cap "$@" invoke 2>&1 | perl -pe 's{.\[\d+m}{}g' | perl -ne 'm{^\s*\*+\s*\[(out|err)\s*::\s*([^]]+)\] ?(.*)} && print "$1 $2 $3\n"' > $tmp_invoke 2>&1
cat $tmp_invoke | awk '{print $2}' | sort -u | while read -r nm_host; do
egrep "^(out|err) $nm_host" $tmp_invoke || true
@@ -25,46 +24,47 @@
set -- $(for a in "$@"; do echo $a; done)
fi
case "$(basename $0)" in
debug)
+ LOCAL_ONLY=true
if [[ -z $1 ]]; then
set "world"
fi
if [[ -n $1 ]]; then
cap $(for a in "$@"; do echo $a.echo; done)
fi
;;
hosts)
+ LOCAL_ONLY=true
{
if [[ -n $1 ]]; then
cap $(for a in "$@"; do echo $a.echo; done)
fi
} 2>&1 | grep eea914aaa8dde6fdae29242b1084a2b0415eefaf | awk '{print $NF}' | sort -u
;;
dna)
+ LOCAL_ONLY=true
{
echo "eea914aaa8dde6fdae29242b1084a2b0415eefaf ---"
if [[ -n $1 ]]; then
cap $(for a in "$@"; do echo $a.yaml; done)
fi
} 2>&1 | grep eea914aaa8dde6fdae29242b1084a2b0415eefaf | sed 's#eea914aaa8dde6fdae29242b1084a2b0415eefaf ##'
;;
task)
- LOCAL_ONLY=
if [[ -n $1 ]]; then
nm_task=$1; shift
set -- $(for a in "$@"; do echo $a.app; done)
fi
bundle exec cap "$@" deploy:lock_migrate deploy:migrate "$nm_task"
;;
*)
- LOCAL_ONLY=
if [[ -n $1 ]]; then
set -- $(for a in "$@"; do echo $a.app; done)
fi
case "$(basename $0)" in
deploy)