Replace strings in files
Project description
rpl
A search/replace utility.
rpl replaces strings with new strings in multiple text files. See the man
page rpl(1) for more information. Install rpl using pip install rpl
.
rpl is distributed under the terms of the GNU General Public License; either version 3 of the License, or (at your option), any later version. See the file COPYING for more details.
usage: rpl [-h] [--version] [--encoding ENCODING] [-i] [-m] [-w] [-b] [-q]
[-v] [-s] [-e] [-F] [--files] [-x GLOB] [-R] [-p] [-f] [-d]
OLD-TEXT NEW-TEXT [FILE ...]
Search and replace text in files.
positional arguments:
OLD-TEXT
NEW-TEXT
FILE `-' or no FILE argument means standard input
options:
-h, --help show this help message and exit
--version show program's version number and exit
--encoding ENCODING specify character set encoding
-i, --ignore-case search case-insensitively
-m, --match-case ignore case when searching, but try to match case of
replacement to case of original, either capitalized,
all upper-case, or mixed
-w, --whole-words whole words (OLD-TEXT matches on word boundaries only)
-b, --backup rename original FILE to FILE~ before replacing
-q, --quiet quiet mode
-v, --verbose verbose mode
-s, --dry-run simulation mode
-e, --escape expand escapes in OLD-TEXT and NEW-TEXT [deprecated]
-F, --fixed-strings treat OLD-TEXT and NEW-TEXT as fixed strings, not
regular expressions
--files OLD-TEXT and NEW-TEXT are file names to read patterns
from
-x GLOB, --glob GLOB modify only files matching the given glob (may be
given more than once)
-R, --recursive search recursively
-p, --prompt prompt before modifying each file
-f, --force ignore errors when trying to preserve attributes
-d, --keep-times keep the modification times on modified files
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
rpl-1.15.7.tar.gz
(25.5 kB
view details)
Built Distribution
rpl-1.15.7-py3-none-any.whl
(21.7 kB
view details)
File details
Details for the file rpl-1.15.7.tar.gz
.
File metadata
- Download URL: rpl-1.15.7.tar.gz
- Upload date:
- Size: 25.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 colorama/0.4.6 importlib-metadata/4.6.4 keyring/23.5.0 pkginfo/1.8.2 readme-renderer/34.0 requests-toolbelt/0.10.1 requests/2.25.1 rfc3986/1.5.0 tqdm/4.57.0 urllib3/1.26.5 CPython/3.10.12
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5eadc62dad539d2e27a1b3c71c2905504a3dbe02380c6c98dbf8505ad9303510 |
|
MD5 | 09477c8833bcd0b7230a7036e9f43366 |
|
BLAKE2b-256 | 40ad840b679493c49e0c4368662e2ddd6296f9bac41e8ee992e0d43d144b4f35 |
File details
Details for the file rpl-1.15.7-py3-none-any.whl
.
File metadata
- Download URL: rpl-1.15.7-py3-none-any.whl
- Upload date:
- Size: 21.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 colorama/0.4.6 importlib-metadata/4.6.4 keyring/23.5.0 pkginfo/1.8.2 readme-renderer/34.0 requests-toolbelt/0.10.1 requests/2.25.1 rfc3986/1.5.0 tqdm/4.57.0 urllib3/1.26.5 CPython/3.10.12
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 620f4b976beeba535dac4aacf834010eeaa1de29985f092ebe79c1ddd9684ea4 |
|
MD5 | 1f4cfe4851fd6de0dbb82a4a801aea00 |
|
BLAKE2b-256 | 21f2632a69db7c105c9e03b33772ac7f30dfd3483e8f05b521fac46761230880 |