https://github.com/rnag/spellcraft
spellcraft is a helper library with useful spells, primarily used by Dataclass Wizard.
https://github.com/rnag/spellcraft
Last synced: 9 months ago
JSON representation
spellcraft is a helper library with useful spells, primarily used by Dataclass Wizard.
- Host: GitHub
- URL: https://github.com/rnag/spellcraft
- Owner: rnag
- License: mit
- Created: 2024-11-05T21:29:43.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2024-11-06T07:17:36.000Z (about 1 year ago)
- Last Synced: 2025-04-05T17:48:11.653Z (9 months ago)
- Language: Rust
- Homepage: http://ritviknag.com/spellcraft/
- Size: 51.8 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# PySpellCraft
[](https://pypi.org/project/spellcraft/)
[](https://pypi.org/project/spellcraft/)
[](https://ritviknag.com/spellcraft/)
[](https://github.com/rnag/spellcraft/actions/workflows/build-and-release.yml)
[](https://github.com/rnag/spellcraft/blob/main/LICENSE)
**SpellCraft** is a helper library that contains useful functions and "spells", primarily designed for use by [Dataclass Wizard].
[Read the documentation.]
[Read the documentation.]: https://ritviknag.com/spellcraft/
[Dataclass Wizard]: https://dataclass-wizard.readthedocs.io
## Installation
```
pip install spellcraft
```
> [!NOTE]
> Requires Python >= 3.9.
## Example
```python
>>> from spellcraft import snake
>>> snake("We carry a new world here, in our hearts.")
'we_carry_a_new_world_here_in_our_hearts'
```
## Development
### Setup
1. Activate a virtual environment:
```sh
python -m venv .venv
source .venv/bin/activate
```
2. Install dev dependencies:
```
pip install .[dev]
```
### Testing
1. Run `maturin develop` to compile the Rust code.
2. Run `make fmt`, `make lint`, and `make test`.
## License
`spellcraft` is distributed under the terms of the MIT License.
See the LICENSE file for full details.
> Copyright (c) 2015 The Rust Project Developers
> Copyright (c) 2022 Kevin Heavey
> Copyright (c) 2024 Ritvik Nag