Skip to main content

Convert shell-like globs to regular expressions

Project description

Tools for converting globs to regular expressions.

This work is derived from Bazaar (bzrlib) and Mikko Ohtamaa. I just created the Python package.

Usage

from globster import Globster

g = Globster(["mydir/", "*.pyc"])
if g.match("/path/to/dir/myscript.pyc"):
    print "it match"


if g.match("/path/to/mydir"):
    print "it match"

License (GPLv2)

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

globster-0.1.0.tar.gz (14.1 kB view details)

Uploaded Source

File details

Details for the file globster-0.1.0.tar.gz.

File metadata

  • Download URL: globster-0.1.0.tar.gz
  • Upload date:
  • Size: 14.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for globster-0.1.0.tar.gz
Algorithm Hash digest
SHA256 c7f8e536bb25e9077ea7f988e2bb6851d5f7ad32c37b0d8862c051a9754e9713
MD5 c4695f698ff71573c674204163b08ef9
BLAKE2b-256 4e6ed752c535e8e6b564f1228ad7add8ab7375f45dba6efb505d6123af1c7c75

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page