Skip to content
Snippets Groups Projects
Commit 2d89be42 authored by Ludovico de Nittis's avatar Ludovico de Nittis :palm_tree:
Browse files

Merge branch 'wip/smcv/failed-log-not-fatal' into 'master'

scripts: Ignore errors when showing diagnostic messages

See merge request !69
parents 1cf127d3 afa2a3de
No related branches found
No related tags found
1 merge request!69scripts: Ignore errors when showing diagnostic messages
Pipeline #19574 passed
...@@ -47,9 +47,9 @@ fi ...@@ -47,9 +47,9 @@ fi
log () { log () {
if [ -n "$use_timestamp" ]; then if [ -n "$use_timestamp" ]; then
timestamp=$(date +'%H:%M:%S.%6N') timestamp=$(date +'%H:%M:%S.%6N')
printf '%s\n' "${timestamp}: ${me}[$$]: $*" >&2 printf '%s\n' "${timestamp}: ${me}[$$]: $*" >&2 || :
else else
printf '%s\n' "${me}[$$]: $*" >&2 printf '%s\n' "${me}[$$]: $*" >&2 || :
fi fi
} }
......
...@@ -13,7 +13,7 @@ me="$(readlink -f "$0")" ...@@ -13,7 +13,7 @@ me="$(readlink -f "$0")"
here="${me%/*}" here="${me%/*}"
log () { log () {
printf '%s\n' "${me}[$$]: $*" >&2 printf '%s\n' "${me}[$$]: $*" >&2 || :
} }
usage () { usage () {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment