Name
at — stdin stdout - file -- opt --help --version
Synopsis
at [options
]time_specification
The at
command runs a shell
command once at a specified time:
$ at 7am next sunday at>echo Remember to go shopping | mail smith
at>lpr $HOME/shopping-list
at> ^D <EOT> job 559 at 2011-09-14 21:30
The time specifications understood by at
are enormously flexible. In general,
you can specify:
A time followed by a date (not a date followed by a time)
Only a date (assumes the current clock time)
Only a time (assumes the very next occurrence, whether today or tomorrow)
A special word like
now
,midnight
, orteatime
(16:00)Any of the preceding followed by an offset, like “+ 3 days”
Dates are acceptable in many forms: december 25 2012
, 25 december 2012
, december 25
, 25
december
, 12/25/2012
,
25.12.2012
, 20121225
, today
, thursday
, next
thursday
, next month
,
next year
, and more. Month names
can be abbreviated to three letters (jan
, feb
, mar
, ...). Times are also flexible:
8pm
, 8
pm
, 8:00pm
, 8:00 pm
, 20:00
, and 2000
are equivalent. Offsets are a plus or
minus sign followed by whitespace and an amount of time: + 3 seconds
, + 2
weeks
, - 1 hour
, and so
on.[16]
If you don’t specify a part of the date or time, at
copies the missing information from the
system date and time. So “next year” means one year from right now,
“thursday” means the upcoming Thursday at the current clock time,
“december 25” means the next upcoming December 25, and “4:30pm”
means the very next occurrence of 4:30 p.m. in the future.
The ...
Get Linux Pocket Guide, 2nd Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.