Metadata-Version: 2.4
Name: stringle
Version: 0.1.0
Summary: String wrangling for bulk find-and-replace operations
Author: Zach Kurtz
License: MIT
License-File: LICENSE
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Requires-Python: >=3.10
Requires-Dist: attrs>=23.0.0
Provides-Extra: dev
Requires-Dist: pytest-cov>=4.0.0; extra == 'dev'
Requires-Dist: pytest>=7.0.0; extra == 'dev'
Description-Content-Type: text/markdown

# stringle

String wrangling for bulk find-and-replace operations. Example:

```python
from stringle import Replacer

replacements = [
    ('old_text', 'new_text'),
    ('another_old', 'another_new'),
]
replacer = Replacer(directory='/path/to/directory')
stats = replacer(replacements)
print(stats)
```

## Features

Core features:
- **Recursive directory traversal** - Process entire directory trees
- **Multiple replacements** - Apply many find-and-replace operations in one pass
- **Flexible filtering**:
  - Ignore specific directories (e.g., `.git`, `.venv`, `node_modules`)
  - Ignore specific files
  - Filter by file extension

Possible future features:
- **Case sensitivity control** - Case-sensitive or case-insensitive matching
- **Regex support** - Use regular expressions for complex patterns
- **Dry run mode** - Preview changes before applying them
- **Detailed statistics** - Get reports on files processed and modified


## Installation

We're [on pypi](https://pypi.org/project/stringle/), so `uv add stringle`.

If working directly on this repo, consider using the [simplest-possible virtual environment](https://gist.github.com/zkurtz/4c61572b03e667a7596a607706463543).
