Created
April 8, 2020 13:20
-
-
Save cesartalves/208e807672dbf09bb5e61242b46c92c6 to your computer and use it in GitHub Desktop.
health-check-crontab
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
# * * * * * DISPLAY=:0 /usr/bin/zenity --info --text="stretch" --title="reminder" | |
# * * * * * /bin/echo "cron works" >> /tmp/file | |
# * * * * * /usr/bin/zenity --notification --text="stretch" --title="reminder" --display=:0.0 | |
# this one on top doesn't work unless we do as below | |
DISPLAY=:0.0 | |
# * * * * * eval "export $(egrep -z DBUS_SESSION_BUS_ADDRESS /proc/$(pgrep -u $LOGNAME gnome-session)/environ)"; /usr/bin/notify-send "TEST" "Crons work!" | |
40 * * * * eval "export $(egrep -z DBUS_SESSION_BUS_ADDRESS /proc/$(pgrep -u $LOGNAME gnome-session)/environ)"; /usr/bin/notify-send "REMINDER" "Check posture!" | |
30 10,14,17 * * * eval "export $(egrep -z DBUS_SESSION_BUS_ADDRESS /proc/$(pgrep -u $LOGNAME gnome-session)/environ)"; /usr/bin/notify-send "REMINDER" "Take a break! (stretch, coffee, etc)" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment