summaryrefslogblamecommitdiffstats
path: root/common/log.sh
blob: 622a9bb2a652b046b7f5919ed28a6a64cf97b7f4 (plain) (tree)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15














                                                      
# log function for displaying output if loging enabled

_log() {
    # only output something,
    # if logging is enabled
    if [ $LOGGING -eq 0 ]; then
	if [ -n "$1" ]; then
	    # echo arguments
	    echo "$@"
	else
	    # echo stdin
	    cat
	fi
    fi 
}