[Prev][Next][Index][Thread]

Re: a sed question...



On Mon, 17 Feb 1997, Nir Soffer wrote:

> > anyone has an idea why I get "sed: Unexpected End-of-file" on this? all
> > the *.htm files are just opened and not even the first line is written...
> > all are 0 bytes long.
> 
> Because Unix is a multitasking OS, the shell opens the file for 
> redirection while sed is running and truncates it just like it should. (> 
> truncates if NO_CLOBBER or whatever isn't set), I know there's a command 
> line option for sed to change files, but it's not reccomended or 
> something. Might I suggest using perl and not a command line with 
> redirections?

becaus that's what SED is all about... IM KVAR, use awk instead, not perl
:-)

NM, someone solved my problem, read on.


References: