From e8b2d94100ec2a5fc5612bc63dc461b74061520b Mon Sep 17 00:00:00 2001 From: Darshaka Pathirana Date: Fri, 4 Dec 2020 12:03:40 +0100 Subject: [PATCH] usr_bin/grml-lock: Fix a couple of shellcheck warnings - SC2086: Double quote to prevent globbing and word splitting. - Ignore SC1091 - SC2230: which is non-standard. Use builtin 'command -v' instead - SC2181: Check exit code directly with e.g. 'if mycmd;', not indirectly with $? --- usr_bin/grml-lock | 1 + 1 file changed, 1 insertion(+) diff --git a/usr_bin/grml-lock b/usr_bin/grml-lock index 27ba082..46e0ab5 100755 --- a/usr_bin/grml-lock +++ b/usr_bin/grml-lock @@ -21,6 +21,7 @@ Usage: just execute $PN without any further options." fi if [ -r /etc/grml/script-functions ] ; then + # shellcheck disable=SC1091 . /etc/grml/script-functions check4progs physlock sudo chpasswd dialog || { echo "Sorry, necessary tools missing - can not continue. Exiting.">&2 ; exit 1 ; } fi -- 2.1.4