Merge branch 'ps/fetch-atomic' into ps/fetch-mirror-optim
* ps/fetch-atomic: fetch: make `--atomic` flag cover pruning of refs fetch: make `--atomic` flag cover backfilling of tags refs: add interface to iterate over queued transactional updates fetch: report errors when backfilling tags fails fetch: control lifecycle of FETCH_HEAD in a single place fetch: backfill tags before setting upstream fetch: increase test coverage of fetches
This commit is contained in:
14
refs.h
14
refs.h
@ -776,6 +776,20 @@ int ref_transaction_abort(struct ref_transaction *transaction,
|
||||
int initial_ref_transaction_commit(struct ref_transaction *transaction,
|
||||
struct strbuf *err);
|
||||
|
||||
/*
|
||||
* Execute the given callback function for each of the reference updates which
|
||||
* have been queued in the given transaction. `old_oid` and `new_oid` may be
|
||||
* `NULL` pointers depending on whether the update has these object IDs set or
|
||||
* not.
|
||||
*/
|
||||
typedef void ref_transaction_for_each_queued_update_fn(const char *refname,
|
||||
const struct object_id *old_oid,
|
||||
const struct object_id *new_oid,
|
||||
void *cb_data);
|
||||
void ref_transaction_for_each_queued_update(struct ref_transaction *transaction,
|
||||
ref_transaction_for_each_queued_update_fn cb,
|
||||
void *cb_data);
|
||||
|
||||
/*
|
||||
* Free `*transaction` and all associated data.
|
||||
*/
|
||||
|
Reference in New Issue
Block a user