Project

General

Profile

« Previous | Next » 

Revision 9374

lib/sh/util.sh: log--: use log+ with 1 instead of log so we don't need a separate log- function

View differences:

lib/sh/util.sh
240 240
	verbosity=$((verbosity - $1)) "${@:2}"
241 241
}
242 242
log-() { log+ $((-($1))); }
243
log++() { log+ 1 "$@"; }
244
log--() { log- 1 "$@"; }
243
log++() { log+  1 "$@"; }
244
log--() { log+ -1 "$@"; }
245 245
alias log_local='declare PS4="$PS4" verbosity="$verbosity"'
246 246
alias log+='log_local; "log+" ' # last space alias-expands next word
247 247
alias log-='log_local; "log-" ' # last space alias-expands next word

Also available in: Unified diff