RPL(1) | General Commands Manual | RPL(1) |
rpl
— replace
strings in files
rpl |
[-LhiwbqvsRepfdt ]
[-x SUFFIX]
⟨old_string⟩
⟨new_string⟩
⟨target_file ...⟩ |
Basic usage is to specify two strings and one or more filenames or directories on the command line. The first string is the string to replace, and the second string is the replacement string.
-h,
--help
-L,
--license
-x
SUFFIX-i,
--ignore-case
-w,
--whole-words
-b,
--backup
-q,
--quiet
-v,
--verbose
-s,
--dry-run
-R,
--recursive
-e,
--escape
-p,
--prompt
-f,
--force
-d,
--keep-times
-t,
--use-tmpdir
TMPDIR
. The default is
to put temporary files in the same directory as the file being
modified.-a,
--all
An effort has been made to make the program behave as much as the
original rpl
as necessary. Where it has been
possible to make improvements, improvements have been made. This
implementation lacks many of the bugs in the original.
Replace all occurences of “F” (on word boundaries) with “A” in all text files under the grades/ directory:
$ rpl -Rwd -x'.txt' 'F' 'A'
grades/
This program was written for Debian as a free replacement for the
non-free rpl
program by Joe Laffey.
Göran Weinholt ⟨weinholt@debian.org⟩.
July 31, 2005 | Debian |