Results 1 to 4 of 4
Hello
I have a directory of several text files formatted as follwoing
[25.8376] [32.1000] B: xab~ir $uw fiy Eindak >axbaAr
[2.8376] [12.1000] B: xab $uw Gde Ginda >qwaAd
[100.8376] [200.1000] ...
- 05-09-2007 #1Just Joined!
- Join Date
- May 2007
- Posts
- 15
script to get a part of line from a text file
Hello
I have a directory of several text files formatted as follwoing
[25.8376] [32.1000] B: xab~ir $uw fiy Eindak >axbaAr
[2.8376] [12.1000] B: xab $uw Gde Ginda >qwaAd
[100.8376] [200.1000] A: xab~ir $gd fhg Qwerak AssbaAr .
it appears that it has three parts seperated by \t tab,I want to get only the last part (red) of line and so on for whole file then all files
putting them in one file as output file formated as a words seperated by spaces
would you please help me to write a script to do that ??
thanx a lot
MD
- 05-10-2007 #2Just Joined!
- Join Date
- May 2007
- Posts
- 15
please is there someone to help in ?
- 05-10-2007 #3
You could take advantage of the fact that there is a colon followed by a space in each line directly where you want to start taking your new lines from
RegardsCode:sed "s/.*: //g" textfile > outputfile
- 05-10-2007 #4Just Joined!
- Join Date
- May 2007
- Posts
- 15
thank you Birdman it's walking


Reply With Quote