From b7b2fa495a5b85efd0657d7c8751ac9e60fbccc2 Mon Sep 17 00:00:00 2001 From: Miles Alan Date: Wed, 5 Aug 2020 20:04:08 -0500 Subject: [PATCH] Add Close Menu entry to sxmo_urlhandler.sh menu --- scripts/core/sxmo_urlhandler.sh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/scripts/core/sxmo_urlhandler.sh b/scripts/core/sxmo_urlhandler.sh index cf466b4..91ad49b 100755 --- a/scripts/core/sxmo_urlhandler.sh +++ b/scripts/core/sxmo_urlhandler.sh @@ -24,6 +24,7 @@ fi COMMAND=$( echo " + Close Menu $(command -v w3m >/dev/null && echo 'w3m URL') $(command -v mpv >/dev/null && echo 'mpv -ao=alsa -v URL') $(command -v mpv >/dev/null && echo 'mpv -ao=alsa -v --ytdl-format='[height<420]' URL') @@ -42,10 +43,10 @@ COMMAND=$( sed -e 's/^\s*//' | dmenu -fn Terminus-15 -p "Pipe URL" -c -l 20 ) -[ -z "$COMMAND" ] && exit 1 +[ "$COMMAND" = "Close Menu" ] && exit 1 +[ -z "$COMMAND" ] && exit 1 RUN=$(echo "$URL" | xargs -IURL echo "$COMMAND") - if [ "$FORK" = fork ]; then st -e sh -c "$RUN" & else