diff --git a/script b/script index ba1179c..1844dcf 100755 --- a/script +++ b/script @@ -25,7 +25,8 @@ EOH } on_interrupt() { - print "Process aborted!\n" + log -l notice "" + log -l notice "Process aborted!" exit 130 } @@ -77,7 +78,7 @@ log() { esac if [ $LEVEL -ge $LOG_VERBOSE_VALUE ]; then - printf "%s" "$*" | while IFS='' read -r LINE; do + printf "%s\n" "$*" | while IFS='' read -r LINE; do printf "%s%s%s\n" "${COLOR:-}" "${TIME:-}" "$LINE" >&2 done fi