Difference between revisions of "Desktop Switch Notification Linux"
From Hack Sphere Labs Wiki
(Created page with "*https://bbs.archlinux.org/viewtopic.php?pid=1371631#p1371631 =script= <code> #!/bin/bash #Description: Using notify-send, pop-up the current workspace number when changing w...") |
(→script) |
||
(One intermediate revision by the same user not shown) | |||
Line 1: | Line 1: | ||
*https://bbs.archlinux.org/viewtopic.php?pid=1371631#p1371631 | *https://bbs.archlinux.org/viewtopic.php?pid=1371631#p1371631 | ||
=script= | =script= | ||
− | < | + | <pre> |
#!/bin/bash | #!/bin/bash | ||
Line 19: | Line 19: | ||
exit 0 | exit 0 | ||
− | </ | + | </pre> |
Latest revision as of 12:15, 16 January 2014
script
#!/bin/bash #Description: Using notify-send, pop-up the current workspace number when changing workspaces #Requires: xfce4-notifyd, libnotify, wmctrl CURRENT_WORKSPACE=$(($(wmctrl -d | grep \* | cut -d' ' -f1)+1)) while true do sleep 1 NEW_WORKSPACE=$(($(wmctrl -d | grep \* | cut -d' ' -f1)+1)) if [ $CURRENT_WORKSPACE -ne $NEW_WORKSPACE ]; then notify-send -t 500 " workspace" "<b><span font='100'>$NEW_WORKSPACE</span></b>" CURRENT_WORKSPACE=$NEW_WORKSPACE fi done exit 0