added keystroke to toggle xnots on and off
This commit is contained in:
parent
8787ace8c0
commit
d79f346551
|
@ -0,0 +1,22 @@
|
||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
running=$(pgrep xnots)
|
||||||
|
curtag=$(herbstclient attr tags.focus.name)
|
||||||
|
|
||||||
|
if [ -z "$running" ]; then
|
||||||
|
exec xnots
|
||||||
|
else
|
||||||
|
visible=
|
||||||
|
for winid in $(xdotool search --class XNots); do
|
||||||
|
hcid=$(printf "0x%x" "$winid")
|
||||||
|
if [ -z "$visible" ]; then
|
||||||
|
visible=$(herbstclient attr clients."$hcid".visible)
|
||||||
|
fi
|
||||||
|
wintag=$(herbstclient attr clients."$hcid".tag)
|
||||||
|
if [ "$visible" = false ] || [ "$wintag" != "$curtag" ]; then
|
||||||
|
herbstclient bring "$winid"
|
||||||
|
else
|
||||||
|
herbstclient set_attr clients."$hcid".minimized true
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
fi
|
|
@ -16,10 +16,6 @@ if hc silent new_attr bool my_picom_is_running; then
|
||||||
picom -b
|
picom -b
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if command -v xnots >/dev/null && hc silent new_attr bool my_xnots_is_running; then
|
|
||||||
xnots &
|
|
||||||
fi
|
|
||||||
|
|
||||||
hc lock
|
hc lock
|
||||||
xsetroot -solid "#1e1e2e" -cursor_name left_ptr &
|
xsetroot -solid "#1e1e2e" -cursor_name left_ptr &
|
||||||
feh --bg-fill ~/.config/herbstluftwm/wallpaper.png
|
feh --bg-fill ~/.config/herbstluftwm/wallpaper.png
|
||||||
|
@ -66,6 +62,7 @@ hc keybind $Mod-Control-r reload
|
||||||
hc keybind $Mod-Shift-c close
|
hc keybind $Mod-Shift-c close
|
||||||
hc keybind $Mod-Return spawn st
|
hc keybind $Mod-Return spawn st
|
||||||
hc keybind $Mod-grave spawn $HOME/skynet/bin/quake-term
|
hc keybind $Mod-grave spawn $HOME/skynet/bin/quake-term
|
||||||
|
hc keybind $Mod-Control-grave spawn $HOME/skynet/bin/xnots-toggle
|
||||||
hc keybind $Mod-Alt-Return spawn ~/skynet/bin/zenvim
|
hc keybind $Mod-Alt-Return spawn ~/skynet/bin/zenvim
|
||||||
hc keybind $Mod-Control-Return spawn firefox
|
hc keybind $Mod-Control-Return spawn firefox
|
||||||
hc keybind Print spawn flameshot gui
|
hc keybind Print spawn flameshot gui
|
||||||
|
@ -159,7 +156,7 @@ hc rule windowtype~'_NET_WM_WINDOW_TYPE_(NOTIFICATION|DOCK|DESKTOP)' manage=off
|
||||||
hc rule class='nvim-zen' fullscreen=on
|
hc rule class='nvim-zen' fullscreen=on
|
||||||
hc rule class='mpv' floating=on
|
hc rule class='mpv' floating=on
|
||||||
hc rule class='sim_arduboy' floating=on
|
hc rule class='sim_arduboy' floating=on
|
||||||
hc rule class='XNots' floating=on tag=8
|
hc rule class='XNots' floating=on
|
||||||
|
|
||||||
hc set tree_style '╾│ ├└╼─┐'
|
hc set tree_style '╾│ ├└╼─┐'
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue