libgit2

git_config_iterator_glob_new

Version:

Iterate over all the config variables whose name matches a pattern

Use git_config_next to advance the iteration and git_config_iterator_free when done.

The regular expression is applied case-sensitively on the normalized form of the variable name: the section and variable parts are lower-cased. The subsection is left unchanged.

Signature

int git_config_iterator_glob_new(git_config_iterator **out, const git_config *cfg, const char *regexp);

Parameters

In
out

pointer to store the iterator

In
cfg

where to ge the variables from

const char *
In
regexp

regular expression to match the names

Returns

int

0 or an error code.

Versions