summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorzachir <zachir@librem.one>2023-08-06 23:00:24 -0500
committerzachir <zachir@librem.one>2023-08-06 23:00:24 -0500
commit63d56b52a85da451a04f63a6948287e7602fc687 (patch)
treed4d3a6d0edac99dd2775d4b1003847638e6f8815
parentc098d43618e72815d0d24660c2c68950cb15f995 (diff)
Fix lwc
-rwxr-xr-xlwc22
1 files changed, 10 insertions, 12 deletions
diff --git a/lwc b/lwc
index 318585f..cf06ed5 100755
--- a/lwc
+++ b/lwc
@@ -18,17 +18,15 @@ esac done
#}}}
#{{{ Check display server if -w or -x not provided
-if [ -z "$DMENU" ]; then
- if [ -n "$WAYLAND_DISPLAY" ]; then
- DMENU="tofi"
- DEFARGS=" -c $HOME/.config/tofi/themes/dmenu_vertical --prompt-text"
- elif [ -n "$DISPLAY" ]; then
- DMENU="dmenu -l 10 -p"
- DEFARGS=""
- else
- print "Can't tell if Wayland or X; what gives?\n"
- exit 1
- fi
+if [ -n "$WAYLAND_DISPLAY" ]; then
+ DMENU="tofi"
+ DEFARGS=" -c $HOME/.config/tofi/themes/dmenu_vertical --prompt-text"
+elif [ -n "$DISPLAY" ]; then
+ DMENU="dmenu -l 10 -p"
+ DEFARGS=""
+else
+ print "Can't tell if Wayland or X; what gives?\n"
+ exit 1
fi
#}}}
@@ -56,7 +54,7 @@ PROFILES="$NATIVE_PROFILES$INT$FLATPAK_PROFILES"
#}}}
#{{{ Choose Profiles
-CHOSEN=`printf "$PROFILES" | $DMENU $DMENU_ARGS librewolf`
+CHOSEN=`printf "$PROFILES" | $DMENU $DEFARGS librewolf $DMENU_ARGS`
[ -z "$CHOSEN" ] && exit 2
if `echo "$CHOSEN" | grep -qE ' F$'`; then
exec flatpak run io.gitlab.librewolf-community -P `echo "$CHOSEN" | sed 's/ F$//'` $URL