diff options
| author | 7ze <shinudonney@tuta.io> | 2021-05-31 06:32:36 +0530 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-05-30 21:02:36 -0400 |
| commit | 1e957b7f901c2bb98f7265d2862d8bc9acdc2f79 (patch) | |
| tree | dbdb0f9d821e531270c39de82b94b41909e65d37 /.local | |
| parent | 76f7656cb2b47e6d21a52b50c285092162872fd4 (diff) | |
| download | eibhear-1e957b7f901c2bb98f7265d2862d8bc9acdc2f79.tar.gz eibhear-1e957b7f901c2bb98f7265d2862d8bc9acdc2f79.tar.zst eibhear-1e957b7f901c2bb98f7265d2862d8bc9acdc2f79.zip | |
Update: dmenumount -Make empty string check more consistent (#955)
* Make empty string check more consistent
Replace explicit empty string check condition with inbuilt POSIX compliant empty string check flag, in adherence with the rest of the script.
* Update test expression
Diffstat (limited to '.local')
| -rwxr-xr-x | .local/bin/dmenumount | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/.local/bin/dmenumount b/.local/bin/dmenumount index b98b6a3..3cb1f81 100755 --- a/.local/bin/dmenumount +++ b/.local/bin/dmenumount @@ -9,7 +9,7 @@ getmount() { \ [ -z "$chosen" ] && exit 1 # shellcheck disable=SC2086 mp="$(find $1 2>/dev/null | dmenu -i -p "Type in mount point.")" || exit 1 - [ "$mp" = "" ] && exit 1 + test -z "$mp" && exit 1 if [ ! -d "$mp" ]; then mkdiryn=$(printf "No\\nYes" | dmenu -i -p "$mp does not exist. Create it?") || exit 1 [ "$mkdiryn" = "Yes" ] && (mkdir -p "$mp" || sudo -A mkdir -p "$mp") |
