libgit2

git_blob_lookup_prefix

Version:

Lookup a blob object from a repository, given a prefix of its identifier (short id).

See

Signature

int git_blob_lookup_prefix(git_blob **blob, git_repository *repo, const git_oid *id, size_t len);

Parameters

Out
blob

pointer to the looked up blob

In
repo

the repo to use when locating the blob.

In
id

identity of the blob to locate.

size_t
In
len

the length of the short identifier

Returns

int

0 or an error code

Versions