[sf-lug] at(1)

Michael Paoli Michael.Paoli at cal.berkeley.edu
Tue Jun 3 05:37:40 PDT 2008


> Date: Tue, 3 Jun 2008 02:58:37 -0700
> From: Rick Moen <rick at linuxmafia.com>
> Subject: Re: [sf-lug] at teatime, etc.
> To: sf-lug at linuxmafia.com
>
> Quoting Michael Paoli (Michael.Paoli at cal.berkeley.edu):
>
> It's been in *BSD since forever.  It's been Thomas Koenig's[1] "at" (e.g.,
> in Linux) since forever.  It's been in at least the last few major
> revisions of Solaris.  I'm _pretty_ sure it's also been in SysV flavours
> generally since at least r4.
>
> So, I guess the next time y'all find yourself hammering Bourne commands
> via an ADM3 onto that VAX running UNIX Version 7 in your basement,
> you're going to be hosed.
>
> Anyway, I forgot to add that you can use syntax like
> $ at noon tomorrow
> or
> $ at teatime today

Yes, also very handy:
$ at now + 15 days
$ at now + 4 hours
etc., e.g. don't forget to clean that cruft later:
$ at now + 15 days << \__EOT__
> exec >>/dev/null 2>&1
> cd /var/local/cruft &&
> find get-rid-of-me-soon-file -type d -prune -o \
> -type f -ctime +12 -exec rm -f -- \{\} \;
> :
> __EOT__
warning: commands will be executed using /bin/sh
job 264 at 2008-06-18 05:25
$ 

> ...which is pretty cool in itself.[2]
>
> [1] Note:  Sorry, no, not Paul Vixie.
> [2] Sorry, "$ at teatime yesterday" doesn't work without the TARDIS
>     extensions.

But for sufficiently ancient versions, some of that newfangled stuff
won't work ;-):
# echo : | at noon
# echo : | at midnight
# echo : | at teatime
at: bad time format

# echo : | at 16
# echo : | at now + 3 days
at: cannot open input: +

#
And it's not a (then) mighty VAX, but a pdp11 ... emulation - takes much
less basement space that way (also freely available - but as in beer,
not freedom ... at least last I checked ... at least for those old UNIX
bits.  The emulator I believe is DFSG free.)




More information about the sf-lug mailing list