fr - find and replace text utility
##########################################################
### Find and Replace Script by Frank Mash ###
##########################################################
--> Usage: /sbin/fr [filename] [search] [replace] [b] [i]
--> ################# EXAMPLES #############################
--> EXAMPLE 1: Find 'Apples' and Replace with 'Oranges'. Create a backup of file and proceed in Interactive mode
----> fr /path/to/file.txt Apples Oranges b i
--> EXAMPLE 2: Find 'Apples' and Replace with 'Oranges'. Create a backup of file and proceed in Non-Interactive mode
----> fr /path/to/file.txt Apples Oranges b
--> EXAMPLE 3: Find 'Apples' and Replace with 'Oranges'. Don't create a backup of file and proceed in Non-Interactive mode
----> fr /path/to/file.txt Apples Oranges
--> ################# END EXAMPLES #########################
--> ################# NOTES ################################
----> Currently you cannot proceed in Interactive mode without creating a backup
--> ################# END NOTES ############################
--> You entered: /sbin/fr help
This custom programming one liner allows you to find and replace using one line. E-mail me at softwareengineer99 on Yahoo's e-mail service if you would like the source code.
Custom programming "One Liner" lookup terms:
fr sed grep
If you would like more information on any of the commands, please feel free to contact me with your programming questions. You can also read other posts on programming code, lookup the programming terms displayed above or visit my network security blog. Other external find replace and software blogs on Technorati.
1 comment:
эта статья очень полезна.
спасибо, что поделились этой статьей.
прокомментировал muhammad solehuddin
Post a Comment