Last active
November 29, 2021 05:04
-
-
Save orschiro/46d75fce983ebf4f5d9aa199cd781606 to your computer and use it in GitHub Desktop.
Temporarily mute Ubuntu's notification for undisturbed work
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
echo "Temporarily muting notifications until aborted..." | |
killall -s SIGSTOP notify-osd | |
keepgoing=1 | |
trap '{ echo "sigint"; keepgoing=0; }' SIGINT | |
while (( keepgoing )); do | |
sleep 5 | |
done | |
echo "Unmuting notifications..." | |
killall -s SIGCONT notify-osd |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment