From aa93b53caf30c8c320dfab6216d892cb777ebd77 Mon Sep 17 00:00:00 2001 From: RGBCube Date: Wed, 3 May 2023 12:51:26 +0300 Subject: [PATCH] Scripts: Use [[ for booleans, always --- rebuild.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/rebuild.sh b/rebuild.sh index 4cacb5c..e613275 100755 --- a/rebuild.sh +++ b/rebuild.sh @@ -1,13 +1,13 @@ #!/bin/sh -if [ "$1" = "--help" ] || [ "$1" = "-h" ]; then +if [[ "$1" = "--help" ]] || [[ "$1" = "-h" ]]; then echo "Usage: rebuild.sh [-h | --help] [-c | --clean-garbage] [machine]" exit fi sudo true -if [ -n "$1" ]; then +if [[ -n "$1" ]]; then machine = $1 else read -p "What machine would you want to build? [$(ls --format=commas machines)]: " machine