|
|
|
|
|||||||||||||||||||||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Display Modes |
|
#1
|
|||
|
|||
|
How to remove 4th word in the first line, separated by space
Tue, 29 Jul 2008 13:00:47 -0700, puzzlecracker wrote:
I have been doing it manually, and would like a short-handed sed or awk for that. > thanks without a sample file I'll just suppose that may well be what you want:-) $ awk 'NR==1{$4=""} 1' yourfile $ sed 's/\([^ ]* *\)\([^ ]* *\)\([^ ]* *\)\([^ ]* *\)\(.*\)/\1\2\3\5/' yourfile |
![]() |
| Viewing: Web Development Archives > FAQs > Unix/Linux > How to remove 4th word in the first line, separated by space |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|
|