From c604b913be8394a683fbda8c021ed49993c50d70 Mon Sep 17 00:00:00 2001 From: Yigit Sever Date: Fri, 6 Nov 2020 20:59:03 +0300 Subject: pause notifications with mod+shift+y --- .config/polybar/config##c.desktop,h.maus | 8 +++++++- .config/polybar/notification_pause.sh | 9 +++++++++ 2 files changed, 16 insertions(+), 1 deletion(-) create mode 100755 .config/polybar/notification_pause.sh (limited to '.config/polybar') diff --git a/.config/polybar/config##c.desktop,h.maus b/.config/polybar/config##c.desktop,h.maus index a489840..e78d49d 100644 --- a/.config/polybar/config##c.desktop,h.maus +++ b/.config/polybar/config##c.desktop,h.maus @@ -52,10 +52,11 @@ font-0 = scientifica:antialias=false;1 font-1 = Lato:size=10;1 font-2 = Raleway:size=10;1 font-3 = FuraCode Nerd Font:size=12;2 +font-4 = Noto Color Emoji:scale=10;2 modules-left = i3 pulseaudio-control spotify mpd modules-center = xwindow -modules-right = cpu focus date time xkeyboard +modules-right = notification_pause cpu focus date time xkeyboard tray-position = right @@ -68,6 +69,11 @@ exec = ~/.config/polybar/focus double-click-left = exec ~/.config/polybar/stop & interval = 10 +[module/notification_pause] +type = custom/script +exec = ~/.config/polybar/notification_pause.sh +interval = 10 + [module/newyork] type = custom/script exec = ~/.config/polybar/new_york.sh diff --git a/.config/polybar/notification_pause.sh b/.config/polybar/notification_pause.sh new file mode 100755 index 0000000..7e59453 --- /dev/null +++ b/.config/polybar/notification_pause.sh @@ -0,0 +1,9 @@ +#!/usr/bin/env bash + +TOGGLE=$HOME/.local/share/.pause_notifications + +if [ ! -e $TOGGLE ]; then + echo +else + printf "🔕" +fi -- cgit v1.2.3-70-g09d2