Hi,
I have a file like this:
.
.
.
set trimspool on
.
.
spool filename
.
.
.
spool off
exit
What I want to do is to append a full path directory to the filename only. So it should read like this:
.
.
.
set trimspool on
.
.
spool /home/john/filename
.
.
.
spool off
exit
Is ther any way I can do this in awk or sed? I tried to grep for "spool" but the result I got back was too many lines since the file itself contains more than 1 spool word. Sometimes it contains only 2 spool words like "spool filename and spool off".
Thank you in advance.
regards,
dbase77
I have a file like this:
.
.
.
set trimspool on
.
.
spool filename
.
.
.
spool off
exit
What I want to do is to append a full path directory to the filename only. So it should read like this:
.
.
.
set trimspool on
.
.
spool /home/john/filename
.
.
.
spool off
exit
Is ther any way I can do this in awk or sed? I tried to grep for "spool" but the result I got back was too many lines since the file itself contains more than 1 spool word. Sometimes it contains only 2 spool words like "spool filename and spool off".
Thank you in advance.
regards,
dbase77