Text Replace
Description
A python package that traverse files based on some regex pattern to select certain files and then update the text in these files using regex.
Install
PyPI: pip install text-replace
Source: git clone https://github.com/Salaah01/text-replace.git
Usage
usage: python -m text_replace [-h] [-d ROOT_DIR] [-f FILE_PATTERN] [-s] [-r] [-t TEXT_PATTERN] [-m {default,relative-url-prefixer}] [-n NEW_TEXT]
Search through files and replace text.
optional arguments:
-h, --help show this help message and exit
-d ROOT_DIR, --root-dir ROOT_DIR
Root directory.
-f FILE_PATTERN, --file-pattern FILE_PATTERN
Regex pattern to follow when searching for files.
-s, --skip-check Show a list of files that will potentially be changed before proceeding.
-r, --recursive Recursively search for files?
-t TEXT_PATTERN, --text-pattern TEXT_PATTERN
Regex pattern for searching for text to replace.
-m {default,relative-url-prefixer}, --mode {default,relative-url-prefixer}
-n NEW_TEXT, --new-text NEW_TEXT
Next text to replace the old text with.
Presets
Preset exist within test_replace/presets and they include helpful shortcuts
to perform certain replaces. These include:
Metadata
Release files for text-replace 0.1.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| text-replace-0.1.2.tar.gz | 5.2 kB | Without provenance | Details for text-replace-0.1.2.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| text_replace-0.1.2-py3-none-any.whl | Python 3 | none | any | Details for text_replace-0.1.2-py3-none-any.whl |
Total release size: 11.6 kB
Release files / text-replace-0.1.2.tar.gz
| Download URL | text-replace-0.1.2.tar.gz |
|---|---|
| Size | 5.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
26aa57c22175b28d363e671655917b644bbeb85acd880ef6c025459f789f2d51
|
|
BLAKE2b-256 checksum How to use checksums |
1bab93bb6bc9f6e07ee292f5bc4e7fad348932fb19b7a4f59dfad33442515472
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.1.1 pkginfo/1.4.2 requests/2.22.0 setuptools/45.2.0 requests-toolbelt/0.8.0 tqdm/4.30.0 CPython/3.8.5
|
Release files / text_replace-0.1.2-py3-none-any.whl
| Download URL | text_replace-0.1.2-py3-none-any.whl |
|---|---|
| Size | 6.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
271e45d44f109e010aadc7f48e077255a8c4468a7e47705d615ebb3b68c8cefe
|
|
BLAKE2b-256 checksum How to use checksums |
d82f2fa03902c0183043a12d1552a51d5f3e99f291a04a2a7921fe7357ce56fb
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.1.1 pkginfo/1.4.2 requests/2.22.0 setuptools/45.2.0 requests-toolbelt/0.8.0 tqdm/4.30.0 CPython/3.8.5
|
Security for text-replace 0.1.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.