AT(1) UNIX Programmer's Manual AT(1) NAME at - execute commands at a later time SYNTAX at [ -m ] time [ day ] [ file ] DESCRIPTION _A_t squirrels away a copy of the named _f_i_l_e (standard input default) to be used as input to _s_h(1) or _c_s_h(1) at a speci- fied later time. A csh script must have a '#' as the first character. If no file is given input is taken from the standard input and the shell is determined by the SHELL environment variable. A _c_d(1) command to the current direc- tory is inserted at the beginning, followed by assignments to all environment variables except TERMCAP. In _c_s_h, the users .cshrc file is then run. When the script is run, it uses the user and group ID of the creator of the copy file. Mail is sent to that user stating when the file ran and giv- ing any output on stdout or stdin. The -m flag causes no mail to be sent. The _t_i_m_e is 1 to 4 digits, with an optional following `A', `P', `N' or `M' for AM, PM, noon or midnight. The letters may be upper or lower case. One and two digit numbers are taken to be hours, three and four digits to be hours and minutes. If no letters follow the digits, a 24 hour clock time is understood. The optional _d_a_y is either (1) a month name followed by a day number, or (2) a day of the week; if the word `week' follows invocation is moved seven days further off. If no day is specified, today is assumed if the time is after the current time. If the time is before the current time, tomorrow is assumed. Names of months and days may be recog- nizably truncated. Examples of legitimate commands are: at 8am jan 24 at 1530 fr week _A_t scripts are executed by periodic execution of the command /_u_s_r/_l_i_b/_a_t_r_u_n from _c_r_o_n(8) typically every 5 minutes. FILES /usr/spool/at/yy.ddd.hhhh.uu activity to be performed at hour _h_h_h_h of year day _d_d_d of year _y_y. _u_u is a unique number. /usr/spool/at/lasttimedone contains _h_h_h_h for last hour of atrun exe- cuted. Printed 7/22/83 1 AT(1) UNIX Programmer's Manual AT(1) /usr/spool/at/past directory of activities now in progress /usr/lib/atrun program that executes activities that are due _p_w_d(1) To find current directory _M_a_i_l(1) To mail output of script SEE ALSO calendar(1), cron(8) DIAGNOSTICS Complains about various syntax errors and times out of range. If the process dies during execution look in /_u_s_r/_s_p_o_o_l/_a_t/_p_a_s_t for the executing file. The mail file is the same name as the executing file except the first number has been changed to 'M'. BUGS Scripts beginning with a '#' are assumed to be csh scripts; this may be inappropriate for scripts that start with "#!/bin/sh". AUTHOR UNIX Version 7. Modified for csh and mail by Peter L. Ward, U.S. Geological Survey, Menlo Park, California. Printed 7/22/83 2