Feb 6, 2006 #1 bobetko Programmer Joined Jan 14, 2003 Messages 155 Location 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 Joined Aug 5, 2002 Messages 9,541 Location RO Hi Code: sed -i '$a ' /path/to/file Feherke. http://rootshell.be/~feherke/ Upvote 0 Downvote
Feb 6, 2006 #3 feherke Programmer Joined Aug 5, 2002 Messages 9,541 Location 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 Joined Jan 14, 2003 Messages 155 Location 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 Joined Aug 5, 2002 Messages 9,541 Location 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/