GNOME Bugzilla – Bug 463856
support @daily and other aliases
Last modified: 2007-11-17 22:34:32 UTC
http://bugs.debian.org/422946 It would be nice if gnome-schedule supported the aliases @reboot, @yearly, annually, @monthly, @weekly, @daily, @midnight and @hourly documented in the debian crontab(5) manual page.
It does support: "@reboot" : '@reboot', "@hourly" : '0 * * * *', "@daily" : '0 0 * * *', "@weekly" : '0 0 * * 0', "@monthly" : '0 0 1 * *', "@yearly" : '0 0 1 1 *' I could include @midnight as well, but I probably would if it was listed where I found the list the first time.. meaning that there are some versions of crontab that doesn't support @midnight. And at this time gnome-schedule only supports the version with the least features to be able to be compatible. Do you know if @midnight is available in both vixie and dcron? - gaute
I added a @daily line to my crontab and gnome-schedule 1.1.0 did not show it in the GUI. 'man 5 crontab' on Debian systems lists these: @reboot Run once, at startup. @yearly Run once a year, "0 0 1 1 *". @annually (same as @yearly) @monthly Run once a month, "0 0 1 * *". @weekly Run once a week, "0 0 * * 0". @daily Run once a day, "0 0 * * *". @midnight (same as @daily) @hourly Run once an hour, "0 * * * *". Dunno about other distributions or dcron (Debian uses vixie cron).
Ok, that is a bug. Could you run gnome-schedule from the command line with the daily entry that you created and post the output here. - gaute
$ crontab -l | grep ^@ @daily echo foo @hourly echo foo $ gnome-schedule regexp: 1
We have support for @reboot, without checking if we are not dealing with vixe cron, the other special expressions will be converted to their standard expression since they mean exactly the same it makes no sense to use them as they are. It will only break support for other crontab daemons on this point. This means; evey time you open and edit an job with one of these @ expressions, even if only to show it and press apply afterwards they will be converted. Dcron is not much more used and as I see it gnome-schedule will only fail if you try to add an "At reboot" record and I have little motivation to enter the forest of different versions and crontab implementations here.. And I will just leave it like this now. - gaute
Hmmm, be nice if I could edit my crontab with crontab -e or gnome-schedule. Thats a minor wishlist though.
You can, if you want. Or I misunderstand.
Ah, I should have been more clear, I think it would be good if the @daily and so on were preserved if they exist in the crontab. I also think that their existence is a fairly good indicator that the cron implementation on the machine supports them, since crontab -e should do syntax checks. If they exist, then you could use that as a hint that they are supported and use them for any new tasks. As I said, both are minor, and I understand if you don't feel like implementing them.