mirror of
https://github.com/tldr-pages/tldr.git
synced 2025-04-29 23:24:55 +02:00
Merge pull request #1041 from tldr-pages/cron
cron: Add job definition example (addresses #822)
This commit is contained in:
commit
ed012db814
1 changed files with 13 additions and 0 deletions
|
@ -1,6 +1,7 @@
|
||||||
# crontab
|
# crontab
|
||||||
|
|
||||||
> Schedule cron jobs to run on a time interval for the current user.
|
> Schedule cron jobs to run on a time interval for the current user.
|
||||||
|
> Job definition format: "(min) (hour) (day_of_month) (month) (day_of_week) command_to_execute".
|
||||||
|
|
||||||
- Edit the crontab file for the current user:
|
- Edit the crontab file for the current user:
|
||||||
|
|
||||||
|
@ -13,3 +14,15 @@
|
||||||
- Remove all cron jobs for the current user:
|
- Remove all cron jobs for the current user:
|
||||||
|
|
||||||
`crontab -r`
|
`crontab -r`
|
||||||
|
|
||||||
|
- Sample job which runs at 10:00 every day. * means any value:
|
||||||
|
|
||||||
|
`0 10 * * * {{path/to/script.sh}}`
|
||||||
|
|
||||||
|
- Sample job which runs every minute on the 3rd of April:
|
||||||
|
|
||||||
|
`* * 3 Apr * {{path/to/script.sh}}`
|
||||||
|
|
||||||
|
- Sample job which runs at 02:30 every Friday:
|
||||||
|
|
||||||
|
`30 2 * * Fri {{path/to/script.sh}}`
|
||||||
|
|
Loading…
Add table
Reference in a new issue