diff options
Diffstat (limited to 'offlineimap-notification')
-rwxr-xr-x | offlineimap-notification | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/offlineimap-notification b/offlineimap-notification new file mode 100755 index 0000000..35abb24 --- /dev/null +++ b/offlineimap-notification @@ -0,0 +1,11 @@ +#!/usr/bin/zsh + +new="$(find $HOME/.mail/*/*/new/ -type f | wc -l)" +old="$(find $HOME/.mail/*/*/cur/ -type f | wc -l)" + +if [ $new -gt 0 ] +then + export DISPLAY=:0; export XAUTHORITY=~/.Xauthority; + notify-send "You've got mail." +fi + |