correct mapping
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
This commit is contained in:
parent
6a19a8ed02
commit
ce61327e51
2 changed files with 8 additions and 3 deletions
|
|
@ -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}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue