Description Usage Arguments Details
Generate a cron job, and pass it to crontab.
1 2 3 4 5 |
command |
A command to execute. |
frequency |
A character string equal to one of
|
at |
The actual time of day at which to execute the
command. When unspecified, we default to |
days_of_month |
Optional; the day(s) of the month on which we execute the command. |
days_of_week |
Optional; the day(s) of the week on which we execute the command. |
months |
Optional; the month(s) of the year on which we execute the command. |
id |
An id, or name, to give to the cronjob task, for easier revision in the future. |
tags |
A set of tags, used for easy listing and retrieval of cron jobs. |
description |
A short description of the job, and its purpose. |
dry_run |
Boolean; if |
user |
The user whose cron jobs we wish to examine. |
The goal is to be able to translate simple English
statements of intent to the actual cron
statement
that could execute that intent. For example,
"I want to run a job daily at 7AM."
is simply
cron_add(<command>, "daily", at="7AM")
Another example, "I want to run a job on the 15th of every month."
is
cron_add(<command>, "monthly",
days_of_month="15th")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.