The callback settings structure
Set the callbacks to be called by the remote when informing the user about the progress of the network operations.
The version
Textual progress from the remote. Text send over the progress side-band will be passed to this function (this is the 'counting objects' output).
Completion is called when different parts of the download process are done (currently unused).
This will be called if the remote host requires authentication in order to connect to it.
Returning GIT_PASSTHROUGH will make libgit2 behave as though this field isn't set.
If cert verification fails, this will be called to let the user make the final decision of whether to allow the connection to proceed. Returns 0 to allow the connection or a negative value to indicate an error.
During the download of new data, this will be regularly called with the current count of progress done by the indexer.
Deprecated callback for reference updates, callers should set update_refs
instead. This is retained for backward compatibility; if you specify both update_refs
and update_tips
, then only the update_refs
function will be called.
Function to call with progress information during pack building. Be aware that this is called inline with pack building operations, so performance may be affected.
Function to call with progress information during the upload portion of a push. Be aware that this is called inline with pack building operations, so performance may be affected.
See documentation of git_push_update_reference_cb
Called once between the negotiation step and the upload. It provides information about what updates will be performed.
Create the transport to use for this operation. Leave NULL to auto-detect.
This will be passed to each of the callbacks in this struct as the last parameter.
Resolve URL before connecting to remote. The returned URL will be used to connect to the remote instead.
This callback is deprecated; users should use git_remote_ready_cb and configure the instance URL instead.
Each time a reference is updated locally, this function will be called with information about it. This should be preferred over the update_tips
callback in this structure.