make shell exec error and normal error look the same for easier grepping in logfiles

Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
This commit is contained in:
Nico Schottelius 2011-09-14 08:45:55 +02:00
parent 03e312dcb7
commit b76c4a5105
2 changed files with 2 additions and 2 deletions

View file

@ -197,7 +197,7 @@ class Cdist:
print(script_fd.read()) print(script_fd.read())
script_fd.close() script_fd.close()
self.exit_error("Non-Zero exit code exit of " + " ".join(*args)) self.exit_error("Command failed (shell): " + " ".join(*args))
def run_or_fail(self, *args, **kargs): def run_or_fail(self, *args, **kargs):
if "remote" in kargs: if "remote" in kargs:

View file

@ -5,7 +5,7 @@ outfile="$1"; shift
( (
for host in "$@"; do for host in "$@"; do
hosts="$hosts $host" hosts="$hosts $host"
cdist config -c ~/p/cdist-nutzung -p $hosts cdist config -c ~/p/cdist-nutzung -p $hosts 2>&1
done done
) | tee "$outfile" ) | tee "$outfile"
echo "----------" echo "----------"