Created
November 25, 2015 21:02
-
-
Save stollcri/9987e685db9fa71a050e to your computer and use it in GitHub Desktop.
Insert text into a file at a specified line number
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # insert ADDTHISTEXT at line 4 of MYFILE.TXT | |
| sed -i '4i\ADDTHISTEXT\' MYFILE.TXT |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment