The script I have is keeping a logfile. This is done using a redirection of the results of a command, this command being held in a variable.
The command seems to work at the command line however when I run it in the script the results are not appended to the log file.
The relevant part of the script is as follows:
atlist1=`echo "job_id" >> /users/emsadmin/current_job_id`
atlist2=`at -l >> /users/emsadmin/current_job_id`
if [ $time -ge 00 -a $time -le 12 ]
then
at 14:00 today < $leadfile
$atlist1
$atlist2
fi
The result in the file I get is:
job_id: Date: Fri Jan 9 13:05:00 MET 2004
The $atlist command does not seem to give a result, it works at the command line.
Does anyone have any ideas.
cheers
simmo
The command seems to work at the command line however when I run it in the script the results are not appended to the log file.
The relevant part of the script is as follows:
atlist1=`echo "job_id" >> /users/emsadmin/current_job_id`
atlist2=`at -l >> /users/emsadmin/current_job_id`
if [ $time -ge 00 -a $time -le 12 ]
then
at 14:00 today < $leadfile
$atlist1
$atlist2
fi
The result in the file I get is:
job_id: Date: Fri Jan 9 13:05:00 MET 2004
The $atlist command does not seem to give a result, it works at the command line.
Does anyone have any ideas.
cheers
simmo