crontog fixed typos & notify-send

notify-send is here because I want to bind this in my i3 config and having information about it.
This commit is contained in:
yuriyurisuki 2018-07-28 08:58:37 +02:00 committed by GitHub
parent 0ff5fcd8cb
commit b9702be50c

5
.scripts/crontog Normal file
View file

@ -0,0 +1,5 @@
#!/bin/bash
# Toggles all cronjobs off/on.
# Stores disabled crontabs in ~/.consaved until restored.
([[ -f ~/.cronsaved ]] && cat ~/.cronsaved | crontab - && rm ~/.cronsaved && notify-send "Cronjobs has been re-enabled." && echo cronjobs re-enabled.) || ( crontab -l > ~/.cronsaved && crontab -r && echo cronjobs saved and disabled.;notify-send "Cronjobs has been saved and disabled.")