-
-
Notifications
You must be signed in to change notification settings - Fork 723
Description
When creating a polybar "button" for jgmenu, I came upon the issue described below. I'd be grateful for a steer on if it is the intended behaviour and if there is anything I could do to avoid it.
I use
- polybar v3.1.0 (build from Arch AUR two days ago)
- i3 v4.14.1
- Arch Linux
Using the default polybar config file (/usr/share/doc/polybar/config), I added:
modules-left = jgmenu bspwm i3
and
[module/jgmenu]
type = custom/script
label-padding = 2
interval = 10
exec = echo "menu"
click-left = "jgmenu_run &"
I found that "jgmenu_run" and "jgmenu" work in terms of launching jgmenu. However, when running jgmenu as a long-running application (default), I don't get polybar back (as described on wiki, so nothing strange about that).
However, "jgmenu_run &" and "jgmenu &" do not launch jgmenu. This is what's peculiar to me. These commands work from the terminal with the "&".
I found that the following works:
click-left = "jgmenu_run >/dev/null 2>&1 &"
The issue can be re-created without jgmenu, by setting "click-left = ~/test.sh &" and then doing the following:
cat <<EOF >~/test.sh
#!/bin/sh
echo "foo"
dmenu_run
EOF
If the 'echo "foo"' line is removed, it works.