好得很程序员自学网

<tfoot draggable='sEl'></tfoot>

at warning: commands will be executed using /bin/

at warning: commands will be executed using /bin/s




Original Poster

Rep:

Here's how I'd do it:

Code:

$ echo 'echo hello >/dev/null' | at now + 2 min >/dev/null 2>&1

This command creates the at job, silently.

Then come back later to investigate what you need:

Code:

$ at -l
$ at -c <jobnumber>
$ atrm <jobnumber>

The first command lists all your current at jobs (jobnumber and time of execution)
The second shows the details of a specific jobnumber
The third deletes a specific jobnumber

[edit]

p.s. - If you want a one-liner that mimics what you are asking to do, here's one:

Original Poster

Rep:

Hi,

thanks!

now I do the following:

echo $cmd | at $time $date 2>&1 | tail -n 1

this is perfect!

RGummi

查看更多关于at warning: commands will be executed using /bin/的详细内容...

  阅读:36次