LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   sed add data to the back of a particular line in a text file (https://www.linuxquestions.org/questions/linux-newbie-8/sed-add-data-to-the-back-of-a-particular-line-in-a-text-file-912123/)

gengwei89 11-06-2011 04:06 AM

sed add data to the back of a particular line in a text file
 
Hi all,

I am currently having a problem as i have to add data to a particular line in a text file, how do i actually do it using the sed command?

eg.
textfile.txt

0,1,2,3,4
2,8,7,5,6
7,8,9,5,6

how do I add an ",2" to the back of line 1?
Advice needed..Thanks

colucix 11-06-2011 04:31 AM

Please post your thread in only one forum. Posting a single thread in the most relevant forum will make it easier for members to help you and will keep the discussion in one place. This thread is being closed because it is a duplicate. Discussion follows here: http://www.linuxquestions.org/questi...t-file-912122/


All times are GMT -5. The time now is 03:27 AM.