diff options
| author | Syndamia <kamen@syndamia.com> | 2022-08-04 17:41:27 +0300 |
|---|---|---|
| committer | Syndamia <kamen@syndamia.com> | 2022-08-04 17:41:27 +0300 |
| commit | 80b4c81b618d4e75b301ac1dd5adfb47f91deca7 (patch) | |
| tree | bc7d94935b273a1aa9b1a1b69c2bbc853c8a32e7 /.a/dunst-toggler-applet.sh | |
| parent | a47706a5bd5ee5be16e3fe443b6008cac9ee741d (diff) | |
| download | dotfiles-80b4c81b618d4e75b301ac1dd5adfb47f91deca7.tar dotfiles-80b4c81b618d4e75b301ac1dd5adfb47f91deca7.tar.gz dotfiles-80b4c81b618d4e75b301ac1dd5adfb47f91deca7.zip | |
Moved a lot of stuff to a new folder called .a
Diffstat (limited to '.a/dunst-toggler-applet.sh')
| -rwxr-xr-x | .a/dunst-toggler-applet.sh | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/.a/dunst-toggler-applet.sh b/.a/dunst-toggler-applet.sh new file mode 100755 index 0000000..e9f253e --- /dev/null +++ b/.a/dunst-toggler-applet.sh @@ -0,0 +1,26 @@ +#!/bin/bash + +function update { + while :; do + curr_status=$(dunstctl is-paused) + + if [[ "$curr_status" != "$prev_status" ]]; then + prev_status=$curr_status + + if [[ "$curr_status" == "true" ]]; then + echo icon:/usr/share/icons/tabler-icon-bell-off.png + echo tooltip:Notifications OFF + else + echo icon:/usr/share/icons/tabler-icon-bell.png + echo tooltip:Notifications ON + fi + fi + + sleep 0.2 + done +} + +update | \ +yad --notification \ + --listen \ + --command="dunstctl set-paused toggle" |
