git_reflog_drop

Remove an entry from the reflog by its index

To ensure there's no gap in the log history, set rewrite_previous_entry param value to 1. When deleting entry n, member old_oid of entry n-1 (if any) will be updated with the value of member new_oid of entry n+1.

extern (C) nothrow @nogc
int
git_reflog_drop

Parameters

reflog libgit2_d.types.git_reflog*

a previously loaded reflog.

idx size_t

the position of the entry to remove. Should be greater than or equal to 0 (zero) and less than git_reflog_entrycount().

rewrite_previous_entry int

1 to rewrite the history; 0 otherwise.

Return Value

Type: int

0 on success, git_error_code.GIT_ENOTFOUND if the entry doesn't exist or an error code.

Meta