PHPackages                             ashleydawson/globtoregex - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. ashleydawson/globtoregex

ActiveLibrary

ashleydawson/globtoregex
========================

Function that converts a glob pattern into a regular expression, extracted from the Symfony Finder component

1.0.0(6y ago)03MITPHPPHP ^7.1CI failing

Since Jun 24Pushed 6y agoCompare

[ Source](https://github.com/AshleyDawson/GlobToRegex)[ Packagist](https://packagist.org/packages/ashleydawson/globtoregex)[ RSS](/packages/ashleydawson-globtoregex/feed)WikiDiscussions master Synced 2mo ago

READMEChangelog (1)Dependencies (2)Versions (2)Used By (0)

Glob to Regex
=============

[](#glob-to-regex)

[![Build Status](https://camo.githubusercontent.com/359fc17739d6e9e1b9981dffd45d3dd12c1216f58e4e5fb970d627acfdc0d727/68747470733a2f2f7472617669732d63692e6f72672f4173686c6579446177736f6e2f476c6f62546f52656765782e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/AshleyDawson/GlobToRegex)

PHP function that converts a glob pattern into a regular expression, extracted from the [Symfony Finder](https://github.com/symfony/finder) component.

Installation
------------

[](#installation)

To install via Composer, do the following:

```
$ composer req ashleydawson/globtoregex
```

Requirements are:

- PHP &gt;= 7.1

Basic Usage
-----------

[](#basic-usage)

Basic usage of the function is as follows:

```
