libgit2

git_config_snapshot

Version:

Create a snapshot of the configuration

Create a snapshot of the current state of a configuration, which allows you to look into a consistent view of the configuration for looking up complex values (e.g. a remote, submodule).

The string returned when querying such a config object is valid until it is freed.

Signature

int git_config_snapshot(git_config **out, git_config *config);

Parameters

In
out

pointer in which to store the snapshot config object

In
config

configuration to snapshot

Returns

int

0 or an error code

Versions