lib.sh: Fix eval $@ in run_cmd()

The wrapped commands were not getting properly "unwrapped" when used with
strings. This was causing  eval "$@" to try to run the first word word in the
unescaped string.
pull/24/head
Jesus Alvarez 11 years ago
parent e6cbf4b6e9
commit 59e81a3305
  1. 4
      lib.sh

@ -69,8 +69,8 @@ run_cmd() {
if [[ $DRY_RUN -eq 1 ]]; then if [[ $DRY_RUN -eq 1 ]]; then
plain "$@" plain "$@"
else else
plain "Running command: $1" plain "Running command: $@"
eval "$@" $@
plain "Command returned: $?" plain "Command returned: $?"
fi fi
} }

Loading…
Cancel
Save