Skip to content

Commit

Permalink
fix logging errors in silent --activate mode
Browse files Browse the repository at this point in the history
  • Loading branch information
MartinNowak committed May 15, 2016
1 parent 55ea050 commit f6dde9b
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions script/install.sh
Expand Up @@ -9,20 +9,24 @@ set -ueo pipefail

# ------------------------------------------------------------------------------

log_() {
echo "${@//$HOME/\~}"
}

log() {
if [ "$verbosity" -gt 0 ]; then
echo "${@//$HOME/\~}"
log_ "$@"
fi
}

logV() {
if [ "$verbosity" -gt 1 ]; then
log "$@";
log_ "$@"
fi
}

logE() {
log "$@" >&2
log_ "$@" >&2
}

fatal() {
Expand Down

0 comments on commit f6dde9b

Please sign in to comment.