GAURAVGUPTA9
17th September 2002, 09:28
Hi
i want to append a new line at the end of my file. how can i do that i am using sed command but not getting the correct syntex.
anyone help....
gaurav

NPRao
17th September 2002, 09:44
Gaurav,

You can look at $man sed for more options for the right syntax.

I think its $ sed 'pattern /a\ ' filename

or to make it much simpler you can also use >> operator, from the basic unix commands.

James
17th September 2002, 15:36
Hi,

Maybe you could try using,

echo "\r" >> myfile

to append a carriage return or

echo "\n" >> myfile

to append a new line.