correct mapping

Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
This commit is contained in:
Nico Schottelius 2010-05-21 09:44:25 +02:00
commit ce61327e51
2 changed files with 8 additions and 3 deletions

View file

@ -22,7 +22,11 @@
host="$(hostname)"
dest="${0%%*/}.${host}.log"
dest="${0##*/}.${host}.log"
prog="| tee ${dest}"
# output to stdout
[ "$1" = "-" ] && prog=""
(
# log, what produced the output
@ -48,4 +52,4 @@ dest="${0%%*/}.${host}.log"
mount
df -h
) 2>&1 | tee "${dest}"
) 2>&1 ${prog}