libgit2

git_index_find

Version:

Find the first index of any entries which point to given path in the Git index.

Signature

int git_index_find(git_index *index, const char *path);

Parameters

In
index

an existing index object

const char *
In
path

path to search

Returns

int

an index >= 0 if found, -1 otherwise

Versions