Skip to content

glob

Find files by name or glob pattern.

Category: Read-only

Parameters

pattern (required)

The glob pattern to match filenames against. Uses Java glob syntax:

Wildcard Matches
* Any sequence of characters within a single directory level
** Any sequence of characters across directory separators
? Any single character
[abc] Any character in the set

Note

**/*.ext requires at least one directory separator before the filename. Use *.ext to match files directly in the search root.

path (optional)
The directory to search. Defaults to the current working directory. Must be a valid directory path if provided.

Output

Newline-separated absolute paths of matching files, sorted by modification time (most recent first). Returns No files found if nothing matches. Only files are returned; directories are never included.

Results are capped at 100. If more matches exist, a truncation note is appended — use a more specific pattern or path to narrow the search.