diff options
author | Benjamin Drung <benjamin.drung@cloud.ionos.com> | 2018-12-10 16:50:01 +0100 |
---|---|---|
committer | Benjamin Drung <benjamin.drung@cloud.ionos.com> | 2018-12-18 13:30:15 +0100 |
commit | f277309e0b6b57ff2f8f9411c026394b7635f3d6 (patch) | |
tree | 9b9e9621b8b535c7d73385c40c44722ce8aba0ed /lsinitramfs | |
parent | 3c8b4c30945ae19529afae398084cfee79b771cf (diff) |
Fix (nearly) all issues found by shellcheck
shellcheck found more issues than SC1074. Address most of these issues.
You can check the shell code by running:
```
shellcheck -e SC1090,SC1091 -s dash hook-functions $(find * -type f
\( -executable ! -name rules -o -regex '.*\.\(post\|pre\).*'
-o -regex "^\(docs\|scripts\)/.*" ! -name '*.md' \))
```
Signed-off-by: Benjamin Drung <benjamin.drung@cloud.ionos.com>
Diffstat (limited to 'lsinitramfs')
-rwxr-xr-x | lsinitramfs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lsinitramfs b/lsinitramfs index a96308d..4f91a6c 100755 --- a/lsinitramfs +++ b/lsinitramfs @@ -4,7 +4,7 @@ set -eu usage() { - echo "Usage: $(basename $0) [-l] <initramfs file>" + echo "Usage: $(basename "$0") [-l] <initramfs file>" } if [ "$#" -eq 0 ] ; then @@ -14,7 +14,7 @@ fi umi_opts="--list" -OPTIONS=`getopt -o hl --long help,long -n "$0" -- "$@"` +OPTIONS=$(getopt -o hl --long help,long -n "$0" -- "$@") # Check for non-GNU getopt if [ $? != 0 ] ; then echo "W: non-GNU getopt" >&2 ; exit 1 ; fi |