![]() |
|
|
|
|
|||||||
| Forums | Portal | Register | Forum Rules | FAQ | Contribute | Members List | Arcade | Search | Today's Posts | Mark Forums Read |
| Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts here. |
|
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| awk: need to extract a line before a pattern | npn35 | Shell Programming and Scripting | 17 | 06-29-2008 07:38 PM |
| Extract Pattern Sequence | jaganadh | Shell Programming and Scripting | 5 | 12-10-2007 08:06 AM |
| Extract if pattern matches | Raynon | Shell Programming and Scripting | 20 | 10-29-2007 01:44 AM |
| Extract the Pattern | aajan | UNIX for Dummies Questions & Answers | 6 | 08-08-2007 01:47 AM |
| Please help! Sed extract a pattern | zhen | Shell Programming and Scripting | 11 | 09-18-2006 09:36 AM |
|
|
Submit Tools | LinkBack | Thread Tools | Search this Thread | Display Modes |
|
#1
|
|||
|
|||
|
extract a particular start and end pattern from a line
hi
In the foll example the whole text in a single line.... i want to extract text from IPTel to RTCPBase.h. want to use this acrooss the whole file Updated: IPTel\platform\core\include\RTCPBase.h \main\MWS2051_Sablime_Int\1 \main\MWS2051_Sablime_Int\IPT2_8_SP1_Integration\1 Thanks Manish |
| Forum Sponsor | ||
|
|
|
#2
|
|||
|
|||
|
Code:
Echo 'Updated: IPTel\platform\core\include\RTCPBase.h \main\MWS2051_Sablime_Int\1 \main\MWS2051_Sablime_Int\IPT2_8_SP1_Integration\1' | awk '{print $2}'
Regards |
|
#3
|
|||
|
|||
|
it is showing only IPTel\platform
|
|
#4
|
|||
|
|||
|
Do you have a space after "IPTel\platform" ?
Regards |
|
#5
|
|||
|
|||
|
no there is no space....
can u try something else i need the solution urgently..... Thanks in advance |
|
#6
|
|||
|
|||
|
cat <your file> | cut -d ' ' -f 1
|
|
#7
|
|||
|
|||
|
Echo 'Updated: IPTel\platform\core\include\RTCPBase.h \main\MWS2051_Sablime_Int\1 \main\MWS2051_Sablime_Int\IPT2_8_SP1_Integration\1' | awk -F" " '{print $2}'
|
|||
| Google The UNIX and Linux Forums |