-
Notifications
You must be signed in to change notification settings - Fork 7
Open
Description
I've run a shellcheck on your script, thought you might be interested in results:
In compress-data.sh line 115:
printout() { [[ $printtype == "l" ]] && printf "$@" || (printf "$@" \
^-- SC2015: Note that A && B || C is not if-then-else. C may run when A is true.
^-- SC2059: Don't use variables in the printf format string. Use printf "..%s.." "$foo".
^-- SC2059: Don't use variables in the printf format string. Use printf "..%s.." "$foo".
In compress-data.sh line 118:
checkconf() {
^-- SC2120: checkconf references arguments, but none are ever passed.
In compress-data.sh line 135:
status() { [[ $1 == 1 ]] && echo "$(bold "OK")" || echo "$(bold "NOT OK")"; }
^-- SC2005: Useless echo? Instead of 'echo $(cmd)', just use 'cmd'.
^-- SC2005: Useless echo? Instead of 'echo $(cmd)', just use 'cmd'.
In compress-data.sh line 164:
confok=1; [[ $debug == 1 ]] && printout "%s Configuration is %s!\n" \
^-- SC2034: confok appears unused. Verify it or export it.
In compress-data.sh line 173:
for ((i=1; i<=$lockwait; i++)); do
^-- SC2004: $/${} is unnecessary on arithmetic variables.
In compress-data.sh line 215:
checkconf ## Check configuration.
^-- SC2119: Use checkconf "$@" if function's $1 should mean script's $1.
In compress-data.sh line 241:
"$(bold $exectime)"
^-- SC2086: Double quote to prevent globbing and word splitting.
returned 1
Metadata
Metadata
Assignees
Labels
No labels