Feb 6, 2006 #1 bobetko Programmer Jan 14, 2003 155 US 1) How to add new line on the end of the file using SED and basic regular expressions? Thanks
Feb 6, 2006 #2 feherke Programmer Aug 5, 2002 9,541 RO Hi Code: sed -i '$a ' /path/to/file Feherke. http://rootshell.be/~feherke/ Upvote 0 Downvote
Feb 6, 2006 #3 feherke Programmer Aug 5, 2002 9,541 RO Hi Code: sed -i '$s/$/\n/' /path/to/input Feherke. http://rootshell.be/~feherke/ Upvote 0 Downvote
Feb 7, 2006 Thread starter #4 bobetko Programmer Jan 14, 2003 155 US Thanks. I've figured I can do something like Code: sed '$a\line to input' input.txt > output.txt Upvote 0 Downvote
Feb 7, 2006 #5 feherke Programmer Aug 5, 2002 9,541 RO Hi Oops ! I do not know why, but I thinked you want to add a new line character. (-: Feherke. http://rootshell.be/~feherke/ Upvote 0 Downvote
Hi Oops ! I do not know why, but I thinked you want to add a new line character. (-: Feherke. http://rootshell.be/~feherke/