Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

swap lines in a file 4

Status
Not open for further replies.

kasparov

Programmer
Feb 13, 2002
203
0
0
GB
Can anyone suggest the best way to swap 2 lines in a file? I want to swap line 14 with line 26.

I assume there must be a quick way of doing this with awk or perl or maybe something else but if so ... I don't know it.

Thanks in advance
 
Agreed - the vi solution's great. Thanks very much.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top