Tom's Guide | Tom's Hardware | Tom's Games
![]() |
![]() |
![]() |
Not sure if that's the right product. I was wondering if someone can help? I am trying to create a shell script taking three parameters for the two lines below. Not sure how to do this.
mv myFile.txt myFile.txt.bak
sed 's/foo/bar/g' myFile.txt.bak > myFile.txtI am not sure about the bak file and txt file and where to input those in the script.
The string to be replaced is foo and the string to replace with is bar. The name of the file to make the substitution is myFile.txt

![]() |
![]() |
![]() |
| Login or Register to Reply | |
| Login | Register |
| Ads by Google |