2016-03-07 17:31:28 +01:00
|
|
|
#!/bin/bash
|
|
|
|
|
2020-01-06 06:25:00 +01:00
|
|
|
imapfilter -c ~/.imapfilter/config.lua
|
|
|
|
mbsync -a
|
2019-12-31 09:48:38 +01:00
|
|
|
notmuch new
|
2016-03-07 17:31:28 +01:00
|
|
|
|
2019-12-31 09:48:38 +01:00
|
|
|
export DISPLAY=:0
|
2020-01-06 06:25:00 +01:00
|
|
|
let inbox=`ls /home/core/Gmail/sanchayan/Inbox/new/|wc -l`
|
|
|
|
let nilenso_inbox=`ls /home/core/Gmail/nilenso/Inbox/new/|wc -l`
|
2016-03-07 17:31:28 +01:00
|
|
|
|
2020-01-06 08:05:17 +01:00
|
|
|
if [ "$inbox" -gt 0 ]; then
|
2020-01-06 06:25:00 +01:00
|
|
|
sudo -u core DISPLAY=:0 DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/1000/bus notify-send "You have $inbox new mails in inbox"
|
2016-03-07 17:31:28 +01:00
|
|
|
fi
|
2019-12-31 09:48:38 +01:00
|
|
|
|
2020-01-06 08:05:17 +01:00
|
|
|
if [ "$nilenso_inbox" -gt 0 ]; then
|
|
|
|
sudo -u core DISPLAY=:0 DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/1000/bus notify-send "You have $nilenso_inbox new mails in Nilenso inbox"
|
|
|
|
fi
|