From eb97848aaf700ab117306609bfe3fe62280953c2 Mon Sep 17 00:00:00 2001 From: Darshaka Pathirana Date: Fri, 5 Mar 2021 16:07:46 +0100 Subject: [PATCH] usr_sbin/grml-config-root: Fix a couple of shellcheck warnings - SC2006: Use $(..) instead of legacy `..`. - SC2230: which is non-standard. Use builtin 'command -v' instead. - SC2086: Double quote to prevent globbing and word splitting. --- usr_sbin/grml-config-root | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/usr_sbin/grml-config-root b/usr_sbin/grml-config-root index e1e1158..db6a2a5 100755 --- a/usr_sbin/grml-config-root +++ b/usr_sbin/grml-config-root @@ -9,8 +9,8 @@ PATH=${PATH:-'/bin/:/sbin/:/usr/bin:/usr/sbin'} # set up some variables -DIALOG=`which dialog` -PN=$(basename $0) +DIALOG=$(command -v dialog) +PN=$(basename "$0") if [ "$(id -ru)" != "0" ] ; then $DIALOG --msgbox "Error: $0 requires root permissions. Exiting." 0 0 -- 2.1.4