libgit2

git_filter_list_load

Version:

Load the filter list for a given path.

This will return 0 (success) but set the output git_filter_list to NULL if no filters are requested for the given file.

Signature

int git_filter_list_load(git_filter_list **filters, git_repository *repo, git_blob *blob, const char *path, git_filter_mode_t mode, uint32_t options);

Parameters

In
filters

Output newly created git_filter_list (or NULL)

In
repo

Repository object that contains path

In
blob

The blob to which the filter will be applied (if known)

const char *
In
path

Relative path of the file to be filtered

In
mode

Filtering direction (WT->ODB or ODB->WT)

uint32_t
In
options

Combination of git_filter_opt_t flags

Returns

int

0 on success (which could still return NULL if no filters are needed for the requested file), < 0 on error

Versions