`fnmatch` is the name for both a C-language standard library function for performing shell-style wildcard pattern-matching against strings, and one of many wrapper implementations exposing the mechanism of C-language `fnmatch` to a higher-level language – i.e. Python, Ruby, `awk`, &c.
fnmatch is both:
- A c-language standard library function,
fnmatch(…), and - Any one of a number of many wrapper implementations exposing the mechanism of c-language
fnmatchto a higher-level language
One of the most noteworthy users of fnmatch(…) is git – specifically, patterns defined in gitignore files are applied using fnmatch(…) – q.v. the gitignore [documentation]4 and the git [source code]5 itself.
Questions about glob pattern-matching can often interchangeably refer to fnmatch patterns as well.
The full signature of the fnmatch(…) C function is:
int fnmatch(char const* pattern,
char const* string,
int flags);
For details of its use, see the man page for fnmatch(3).