Skip to main content
HandyWeb

Glob Tester

Try glob patterns like src/**/*.ts and !*.test.ts on a list of paths, and see which files match and which pattern decided.

! at the start of a line excludes, and # starts a comment. Later patterns win over earlier ones.

0 characters0 bytes

* stays in one folder, ** goes to any depth, ? is one character, [a-z] is one of, and {a,b} is one of several options.

How to Use It

  1. Type the patterns.
  2. Paste the paths.
  3. Read the matches and the deciding pattern of each path.

Questions and Answers

How is * different from **?

* stays in one folder and does not cross /. ** as a whole path segment matches any number of folders, even zero.

Good to Know

The common glob rules are used. Tools differ in details: for example, .gitignore matches a pattern without / at any depth, but this tool does not.

Source code of this tool (opens in a new tab)Report a problem on GitHub (opens in a new tab)