Common Regexes via Python
Project description
Regexes
Regex Finder for Python
Easy regex finder for Python
Usage:
- For extracting all possible info from string
from regexes import Regexes
string = """
Hello My name is Berkay and this is my project
bekxxx3@gmail.com, beskilo@doner.com,
05323450002,
05430000778,
pythoncibeko@bekocanholding.com
"""
ret = Regexes(data=string).find_reg()
print(ret)
# ---------------------------
# {'btc_addresses': [],
# 'credit_cards': [],
# 'dates': [],
# 'emails': ['bekxxx3@gmail.com',
# 'beskilo@doner.com',
# 'pythoncibeko@bekocanholding.com'],
# 'hex_colors': [],
# 'ips': [],
# 'ipv6s': [],
# 'links': ['gmail.com', 'doner.com', 'bekocanholding.com'],
# 'phones': ['05323450002', '05430000778'],
# 'phones_with_exts': [],
# 'po_boxes': [],
# 'prices': [],
# 'ssn_number': [],
# 'street_addresses': [],
# 'times': [],
# 'zip_codes': []}
- For specific type of info
from regexes import Regexes
string = """
Hello My name is Berkay and this is my project
bekxxx3@gmail.com, beskilo@doner.com,
05323450002,
05430000778,
pythoncibeko@bekocanholding.com
"""
ret = Regexes(data=string, dtype="emails").find_reg() # * Just add dtype arg
print(ret)
# ---------------------------
# {'emails': ['bekxxx3@gmail.com',
# 'beskilo@doner.com',
# 'pythoncibeko@bekocanholding.com']}
Credit: CommonRegex
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Regexes-0.0.1.tar.gz
(16.8 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
Regexes-0.0.1-py3-none-any.whl
(16.9 kB
view details)
File details
Details for the file Regexes-0.0.1.tar.gz.
File metadata
- Download URL: Regexes-0.0.1.tar.gz
- Upload date:
- Size: 16.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.10.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
16ce8e13a01f0955d925fde3df9a4aec2297a7f40ff2b7d17aafba812030d775
|
|
| MD5 |
ea7d596c83dc7e5eddd344c88d702115
|
|
| BLAKE2b-256 |
69db980f72728c58fe4b006a5ac89f29db266cdafabfd1229505e33baca578c9
|
File details
Details for the file Regexes-0.0.1-py3-none-any.whl.
File metadata
- Download URL: Regexes-0.0.1-py3-none-any.whl
- Upload date:
- Size: 16.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.10.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
520937025118e83906748a938880fd8f19630fa88d4de4021b8786a8866c50c0
|
|
| MD5 |
2d4dafabacb7614a385de43bfb76e2f8
|
|
| BLAKE2b-256 |
d3b9bb044ec1d76182d29fdc9d4ef7ad3ebb827c15e4b0e40fc05642daa484da
|