Skip to main content
Travis CI build status PyPI Package latest release PyPI Package monthly downloads Supported versions Supported implementations Wheel packaging support Test line coverage Test branch coverage

A simplified interface to Python’s regular expression (re) string search. Eliminates steps and provides simpler access to results. As a bonus, also provides compatible way to access Unix glob searches.

Usage

Python regular expressions are powerful, but the language’s lack of an en passant (in passing) assignment requires a preparatory motion and then a test:

import re

match = re.search(pattern, some_string)
if match:
    print match.group(1)

With simplere, you can do it in fewer steps:

from simplere import *

if match / re.search(pattern, some_string):
    print match[1]

That’s particularly valuable in complex search-and-manipulate code that requires multiple levels of searching along with pre-conditions, error checking, and post-match cleanup, formatting, and actions.

As a bonus, simplere also provides simple glob access.:

if 'globtastic' in Glob('glob*'):
    print "Yes! It is!"
else:
    raise ValueError('OH YES IT IS!')

It can also conveniently match against multiple glob patterns, and/or do case-insensitive glob searches.

See Read the Docs for the full installation and usage documentation.

Release files for simplere 1.2.9

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for simplere 1.2.9
File Size Uploaded
simplere-1.2.9.zip 20.7 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for simplere 1.2.9
File Interpreter ABI Platform
simplere-1.2.9-py2.py3-none-any.whl Python 3, Python 2 none any Details

Total release size: 27.7 kB

Release files / simplere-1.2.9.zip

Download URL simplere-1.2.9.zip
Size 20.7 kB
Tags Source
SHA-256 checksum
How to use checksums
3a076aec5c24594bf854b7cce9dd7db820a1c0f0e200fe73258ec2bee436f3e6
BLAKE2b-256 checksum
How to use checksums
a75bbbefb114181d069f4a7abf47526d23b66e5da1221eb0e55efb1f3c6a7696
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release files / simplere-1.2.9-py2.py3-none-any.whl

Download URL simplere-1.2.9-py2.py3-none-any.whl
Size 7.0 kB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
d1e454914200b09b2bfa171a9878507fc9fe9e31020451f28f58322e7f8732ac
BLAKE2b-256 checksum
How to use checksums
8c0ac26ee96bdb1dabda7077acca94350c7d5ec4ce2c389fa464be88bd1675df
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release history Release notifications | RSS feed

1.2.13

2 release files

1.2.11

2 release files

This release

1.2.9 This release

2 release files

1.2.8

3 release files

1.2.7

3 release files

1.2.6

3 release files

1.2.5

3 release files

1.2.0

3 release files

1.1.1

3 release files

1.1.0

3 release files

1.0.9

2 release files

1.0.8

2 release files

1.0.7

2 release files

1.0.5

2 release files

1.0.3

2 release files

1.0.2

2 release files

1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page