Created
December 18, 2017 18:34
-
-
Save jondlm/9260af123a07b774503930080dc631b4 to your computer and use it in GitHub Desktop.
Somtimes I forget to open Outlook in the morning, this helps as a cron task
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
#!/usr/bin/env bash | |
# vim: set syntax=sh | |
ps aux | grep -v "grep" | grep "Microsoft Outlook" > /dev/null | |
outlook_ret=$? | |
day=`date +%u` | |
# Make sure it's a weekday and Outlook is running | |
if [ "$day" -ge 1 -a "$day" -le 5 -a "$outlook_ret" -gt 0 ]; then | |
osascript -e 'display notification "Please start Outlook" with title "Nag Bot"' | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Only runs on a Mac with
gdate