The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
.
google unix.com




View Single Post in the UNIX and Linux Forums - Click on the Thread or Permalink to View Entire Thread -->
  #12 (permalink)  
Old 06-26-2009
dinesh1985 dinesh1985 is offline
Registered User
  
 

Join Date: Jun 2009
Posts: 31
Thanks for your replies ..i ll try it and update

---------- Post updated 06-26-09 at 03:20 AM ---------- Previous update was 06-25-09 at 03:54 AM ----------

I donot want to redirect to any new file. I want to delete the line from the file itself.
I have tried sed -i '3d' to delete the 3rd line. But my shell is not recognizing sed -i.

I have tried sed '3d' <filename> ..it is displaying the file without the 3rd line. But the 3rd line is not permanently deleted. Can anyone please help