subprompt/README.md

26 lines
513 B
Markdown
Raw Normal View History

2022-11-11 16:03:39 -05:00
# subprompt
2022-11-15 12:27:47 -05:00
Interactively change every line matching a regex in multiple files.
## Installation
Through PyPI:
2022-11-11 16:03:39 -05:00
```
2022-11-15 12:27:47 -05:00
python3.9 -m pip install subprompt
2022-11-11 16:03:39 -05:00
```
2022-11-15 12:27:47 -05:00
## Usage
2022-11-11 17:07:41 -05:00
```
2022-11-15 12:27:47 -05:00
usage: subprompt.py [-h] (-d | -r R) [-n N] REGEX FILES [FILES ...]
Modifies lines matched by a regex interactively
positional arguments:
REGEX
FILES
optional arguments:
-h, --help show this help message and exit
-d delete line
-r R replace match with expression
-n N size of lines preview (default=3)
2022-11-11 17:07:41 -05:00
```