1752802 Members
5559 Online
108789 Solutions
New Discussion

Re: Add return feed.

 
SOLVED
Go to solution
H.Merijn Brand (procura
Honored Contributor

Re: Add return feed.

remove the ^M from the last line only:

# perl -pe 'BEGIN{$/=undef}s/\r\Z//' infile >outfile
Enjoy, Have FUN! H.Merijn
Leif Halvarsson_2
Honored Contributor

Re: Add return feed.

Hi
If you want to add a linefeed only to the last line this is the same as appending a linefeed to the file.
echo '\n' >>filename.