Metadata-Version: 2.1
Name: remagic
Version: 0.1.2a0
Summary: Working with RegEx made easy!
Home-page: https://github.com/ificiana/remagic
License: MIT
Keywords: regex,remagic
Author: Ificiana
Author-email: ificiana@gmail.com
Requires-Python: >=3.7.2,<4.0.0
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.7
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Provides-Extra: regex
Requires-Dist: importlib_metadata (>=4.5.0,<5.0.0); python_version < "3.8"
Requires-Dist: regex (>=2022.9.13,<2023.0.0); extra == "regex"
Project-URL: Documentation, https://ificiana.github.io/remagic
Project-URL: Repository, https://github.com/ificiana/remagic
Description-Content-Type: text/markdown

[![Coverage Status](https://coveralls.io/repos/github/ificiana/remagic/badge.svg?branch=main)](https://coveralls.io/github/ificiana/remagic?branch=main)
![PyPI - Downloads](https://img.shields.io/pypi/dm/remagic)
![PyPI - Python Version](https://img.shields.io/pypi/pyversions/remagic)
![PyPI - License](https://img.shields.io/pypi/l/remagic)

# remagic

Working with regex made easier!
Partly inspired from `magic-regexp` for Node

```py
from remagic import *

pattern1 = create(DIGIT)  # matches any digit
pattern2 = char_in("aeiou")  # matches any char in "aeiou"
pattern3 = ~pattern2  # negates the pattern in pattern2, 
# i.e. match everything except characters in "aeiou"
# Note: remagic 0.1.1 doesn't support the ~ syntax
# use char_not_in("aeiou") instead
pattern4 = pattern1 + pattern3
# finally compile, use standard flags as optional argument
R = pattern4.compile()
# use the regex later
``` 

## Installation

Install from PyPI:
`pip install remagic`

## Work in Progress!

### Documentation

TODO: [docs](https://ificiana.github.io/remagic)

### Known bugs

- improper behaviour with `any_of`

