Edit File by line
/home/barbar84/public_h.../wp-conte.../plugins/sujqvwi/AnonR/anonr.TX.../opt/imh-pyth.../include/git2
File: remote.h
/*
[0] Fix | Delete
* Copyright (C) the libgit2 contributors. All rights reserved.
[1] Fix | Delete
*
[2] Fix | Delete
* This file is part of libgit2, distributed under the GNU GPL v2 with
[3] Fix | Delete
* a Linking Exception. For full terms see the included COPYING file.
[4] Fix | Delete
*/
[5] Fix | Delete
#ifndef INCLUDE_git_remote_h__
[6] Fix | Delete
#define INCLUDE_git_remote_h__
[7] Fix | Delete
[8] Fix | Delete
#include "common.h"
[9] Fix | Delete
#include "repository.h"
[10] Fix | Delete
#include "refspec.h"
[11] Fix | Delete
#include "net.h"
[12] Fix | Delete
#include "indexer.h"
[13] Fix | Delete
#include "strarray.h"
[14] Fix | Delete
#include "transport.h"
[15] Fix | Delete
#include "pack.h"
[16] Fix | Delete
#include "proxy.h"
[17] Fix | Delete
[18] Fix | Delete
/**
[19] Fix | Delete
* @file git2/remote.h
[20] Fix | Delete
* @brief Git remote management functions
[21] Fix | Delete
* @defgroup git_remote remote management functions
[22] Fix | Delete
* @ingroup Git
[23] Fix | Delete
* @{
[24] Fix | Delete
*/
[25] Fix | Delete
GIT_BEGIN_DECL
[26] Fix | Delete
[27] Fix | Delete
/**
[28] Fix | Delete
* Add a remote with the default fetch refspec to the repository's configuration.
[29] Fix | Delete
*
[30] Fix | Delete
* @param out the resulting remote
[31] Fix | Delete
* @param repo the repository in which to create the remote
[32] Fix | Delete
* @param name the remote's name
[33] Fix | Delete
* @param url the remote's url
[34] Fix | Delete
* @return 0, GIT_EINVALIDSPEC, GIT_EEXISTS or an error code
[35] Fix | Delete
*/
[36] Fix | Delete
GIT_EXTERN(int) git_remote_create(
[37] Fix | Delete
git_remote **out,
[38] Fix | Delete
git_repository *repo,
[39] Fix | Delete
const char *name,
[40] Fix | Delete
const char *url);
[41] Fix | Delete
[42] Fix | Delete
/**
[43] Fix | Delete
* Remote creation options flags
[44] Fix | Delete
*/
[45] Fix | Delete
typedef enum {
[46] Fix | Delete
/** Ignore the repository apply.insteadOf configuration */
[47] Fix | Delete
GIT_REMOTE_CREATE_SKIP_INSTEADOF = (1 << 0),
[48] Fix | Delete
[49] Fix | Delete
/** Don't build a fetchspec from the name if none is set */
[50] Fix | Delete
GIT_REMOTE_CREATE_SKIP_DEFAULT_FETCHSPEC = (1 << 1),
[51] Fix | Delete
} git_remote_create_flags;
[52] Fix | Delete
[53] Fix | Delete
/**
[54] Fix | Delete
* Remote creation options structure
[55] Fix | Delete
*
[56] Fix | Delete
* Initialize with `GIT_REMOTE_CREATE_OPTIONS_INIT`. Alternatively, you can
[57] Fix | Delete
* use `git_remote_create_options_init`.
[58] Fix | Delete
*
[59] Fix | Delete
*/
[60] Fix | Delete
typedef struct git_remote_create_options {
[61] Fix | Delete
unsigned int version;
[62] Fix | Delete
[63] Fix | Delete
/**
[64] Fix | Delete
* The repository that should own the remote.
[65] Fix | Delete
* Setting this to NULL results in a detached remote.
[66] Fix | Delete
*/
[67] Fix | Delete
git_repository *repository;
[68] Fix | Delete
[69] Fix | Delete
/**
[70] Fix | Delete
* The remote's name.
[71] Fix | Delete
* Setting this to NULL results in an in-memory/anonymous remote.
[72] Fix | Delete
*/
[73] Fix | Delete
const char *name;
[74] Fix | Delete
[75] Fix | Delete
/** The fetchspec the remote should use. */
[76] Fix | Delete
const char *fetchspec;
[77] Fix | Delete
[78] Fix | Delete
/** Additional flags for the remote. See git_remote_create_flags. */
[79] Fix | Delete
unsigned int flags;
[80] Fix | Delete
} git_remote_create_options;
[81] Fix | Delete
[82] Fix | Delete
#define GIT_REMOTE_CREATE_OPTIONS_VERSION 1
[83] Fix | Delete
#define GIT_REMOTE_CREATE_OPTIONS_INIT {GIT_REMOTE_CREATE_OPTIONS_VERSION}
[84] Fix | Delete
[85] Fix | Delete
/**
[86] Fix | Delete
* Initialize git_remote_create_options structure
[87] Fix | Delete
*
[88] Fix | Delete
* Initializes a `git_remote_create_options` with default values. Equivalent to
[89] Fix | Delete
* creating an instance with `GIT_REMOTE_CREATE_OPTIONS_INIT`.
[90] Fix | Delete
*
[91] Fix | Delete
* @param opts The `git_remote_create_options` struct to initialize.
[92] Fix | Delete
* @param version The struct version; pass `GIT_REMOTE_CREATE_OPTIONS_VERSION`.
[93] Fix | Delete
* @return Zero on success; -1 on failure.
[94] Fix | Delete
*/
[95] Fix | Delete
GIT_EXTERN(int) git_remote_create_options_init(
[96] Fix | Delete
git_remote_create_options *opts,
[97] Fix | Delete
unsigned int version);
[98] Fix | Delete
[99] Fix | Delete
/**
[100] Fix | Delete
* Create a remote, with options.
[101] Fix | Delete
*
[102] Fix | Delete
* This function allows more fine-grained control over the remote creation.
[103] Fix | Delete
*
[104] Fix | Delete
* Passing NULL as the opts argument will result in a detached remote.
[105] Fix | Delete
*
[106] Fix | Delete
* @param out the resulting remote
[107] Fix | Delete
* @param url the remote's url
[108] Fix | Delete
* @param opts the remote creation options
[109] Fix | Delete
* @return 0, GIT_EINVALIDSPEC, GIT_EEXISTS or an error code
[110] Fix | Delete
*/
[111] Fix | Delete
GIT_EXTERN(int) git_remote_create_with_opts(
[112] Fix | Delete
git_remote **out,
[113] Fix | Delete
const char *url,
[114] Fix | Delete
const git_remote_create_options *opts);
[115] Fix | Delete
[116] Fix | Delete
/**
[117] Fix | Delete
* Add a remote with the provided fetch refspec (or default if NULL) to the repository's
[118] Fix | Delete
* configuration.
[119] Fix | Delete
*
[120] Fix | Delete
* @param out the resulting remote
[121] Fix | Delete
* @param repo the repository in which to create the remote
[122] Fix | Delete
* @param name the remote's name
[123] Fix | Delete
* @param url the remote's url
[124] Fix | Delete
* @param fetch the remote fetch value
[125] Fix | Delete
* @return 0, GIT_EINVALIDSPEC, GIT_EEXISTS or an error code
[126] Fix | Delete
*/
[127] Fix | Delete
GIT_EXTERN(int) git_remote_create_with_fetchspec(
[128] Fix | Delete
git_remote **out,
[129] Fix | Delete
git_repository *repo,
[130] Fix | Delete
const char *name,
[131] Fix | Delete
const char *url,
[132] Fix | Delete
const char *fetch);
[133] Fix | Delete
[134] Fix | Delete
/**
[135] Fix | Delete
* Create an anonymous remote
[136] Fix | Delete
*
[137] Fix | Delete
* Create a remote with the given url in-memory. You can use this when
[138] Fix | Delete
* you have a URL instead of a remote's name.
[139] Fix | Delete
*
[140] Fix | Delete
* @param out pointer to the new remote objects
[141] Fix | Delete
* @param repo the associated repository
[142] Fix | Delete
* @param url the remote repository's URL
[143] Fix | Delete
* @return 0 or an error code
[144] Fix | Delete
*/
[145] Fix | Delete
GIT_EXTERN(int) git_remote_create_anonymous(
[146] Fix | Delete
git_remote **out,
[147] Fix | Delete
git_repository *repo,
[148] Fix | Delete
const char *url);
[149] Fix | Delete
[150] Fix | Delete
/**
[151] Fix | Delete
* Create a remote without a connected local repo
[152] Fix | Delete
*
[153] Fix | Delete
* Create a remote with the given url in-memory. You can use this when
[154] Fix | Delete
* you have a URL instead of a remote's name.
[155] Fix | Delete
*
[156] Fix | Delete
* Contrasted with git_remote_create_anonymous, a detached remote
[157] Fix | Delete
* will not consider any repo configuration values (such as insteadof url
[158] Fix | Delete
* substitutions).
[159] Fix | Delete
*
[160] Fix | Delete
* @param out pointer to the new remote objects
[161] Fix | Delete
* @param url the remote repository's URL
[162] Fix | Delete
* @return 0 or an error code
[163] Fix | Delete
*/
[164] Fix | Delete
GIT_EXTERN(int) git_remote_create_detached(
[165] Fix | Delete
git_remote **out,
[166] Fix | Delete
const char *url);
[167] Fix | Delete
[168] Fix | Delete
/**
[169] Fix | Delete
* Get the information for a particular remote
[170] Fix | Delete
*
[171] Fix | Delete
* The name will be checked for validity.
[172] Fix | Delete
* See `git_tag_create()` for rules about valid names.
[173] Fix | Delete
*
[174] Fix | Delete
* @param out pointer to the new remote object
[175] Fix | Delete
* @param repo the associated repository
[176] Fix | Delete
* @param name the remote's name
[177] Fix | Delete
* @return 0, GIT_ENOTFOUND, GIT_EINVALIDSPEC or an error code
[178] Fix | Delete
*/
[179] Fix | Delete
GIT_EXTERN(int) git_remote_lookup(git_remote **out, git_repository *repo, const char *name);
[180] Fix | Delete
[181] Fix | Delete
/**
[182] Fix | Delete
* Create a copy of an existing remote. All internal strings are also
[183] Fix | Delete
* duplicated. Callbacks are not duplicated.
[184] Fix | Delete
*
[185] Fix | Delete
* Call `git_remote_free` to free the data.
[186] Fix | Delete
*
[187] Fix | Delete
* @param dest pointer where to store the copy
[188] Fix | Delete
* @param source object to copy
[189] Fix | Delete
* @return 0 or an error code
[190] Fix | Delete
*/
[191] Fix | Delete
GIT_EXTERN(int) git_remote_dup(git_remote **dest, git_remote *source);
[192] Fix | Delete
[193] Fix | Delete
/**
[194] Fix | Delete
* Get the remote's repository
[195] Fix | Delete
*
[196] Fix | Delete
* @param remote the remote
[197] Fix | Delete
* @return a pointer to the repository
[198] Fix | Delete
*/
[199] Fix | Delete
GIT_EXTERN(git_repository *) git_remote_owner(const git_remote *remote);
[200] Fix | Delete
[201] Fix | Delete
/**
[202] Fix | Delete
* Get the remote's name
[203] Fix | Delete
*
[204] Fix | Delete
* @param remote the remote
[205] Fix | Delete
* @return a pointer to the name or NULL for in-memory remotes
[206] Fix | Delete
*/
[207] Fix | Delete
GIT_EXTERN(const char *) git_remote_name(const git_remote *remote);
[208] Fix | Delete
[209] Fix | Delete
/**
[210] Fix | Delete
* Get the remote's url
[211] Fix | Delete
*
[212] Fix | Delete
* If url.*.insteadOf has been configured for this URL, it will
[213] Fix | Delete
* return the modified URL.
[214] Fix | Delete
*
[215] Fix | Delete
* @param remote the remote
[216] Fix | Delete
* @return a pointer to the url
[217] Fix | Delete
*/
[218] Fix | Delete
GIT_EXTERN(const char *) git_remote_url(const git_remote *remote);
[219] Fix | Delete
[220] Fix | Delete
/**
[221] Fix | Delete
* Get the remote's url for pushing
[222] Fix | Delete
*
[223] Fix | Delete
* If url.*.pushInsteadOf has been configured for this URL, it
[224] Fix | Delete
* will return the modified URL.
[225] Fix | Delete
*
[226] Fix | Delete
* @param remote the remote
[227] Fix | Delete
* @return a pointer to the url or NULL if no special url for pushing is set
[228] Fix | Delete
*/
[229] Fix | Delete
GIT_EXTERN(const char *) git_remote_pushurl(const git_remote *remote);
[230] Fix | Delete
[231] Fix | Delete
/**
[232] Fix | Delete
* Set the remote's url in the configuration
[233] Fix | Delete
*
[234] Fix | Delete
* Remote objects already in memory will not be affected. This assumes
[235] Fix | Delete
* the common case of a single-url remote and will otherwise return an error.
[236] Fix | Delete
*
[237] Fix | Delete
* @param repo the repository in which to perform the change
[238] Fix | Delete
* @param remote the remote's name
[239] Fix | Delete
* @param url the url to set
[240] Fix | Delete
* @return 0 or an error value
[241] Fix | Delete
*/
[242] Fix | Delete
GIT_EXTERN(int) git_remote_set_url(git_repository *repo, const char *remote, const char* url);
[243] Fix | Delete
[244] Fix | Delete
/**
[245] Fix | Delete
* Set the remote's url for pushing in the configuration.
[246] Fix | Delete
*
[247] Fix | Delete
* Remote objects already in memory will not be affected. This assumes
[248] Fix | Delete
* the common case of a single-url remote and will otherwise return an error.
[249] Fix | Delete
*
[250] Fix | Delete
*
[251] Fix | Delete
* @param repo the repository in which to perform the change
[252] Fix | Delete
* @param remote the remote's name
[253] Fix | Delete
* @param url the url to set
[254] Fix | Delete
*/
[255] Fix | Delete
GIT_EXTERN(int) git_remote_set_pushurl(git_repository *repo, const char *remote, const char* url);
[256] Fix | Delete
[257] Fix | Delete
/**
[258] Fix | Delete
* Add a fetch refspec to the remote's configuration
[259] Fix | Delete
*
[260] Fix | Delete
* Add the given refspec to the fetch list in the configuration. No
[261] Fix | Delete
* loaded remote instances will be affected.
[262] Fix | Delete
*
[263] Fix | Delete
* @param repo the repository in which to change the configuration
[264] Fix | Delete
* @param remote the name of the remote to change
[265] Fix | Delete
* @param refspec the new fetch refspec
[266] Fix | Delete
* @return 0, GIT_EINVALIDSPEC if refspec is invalid or an error value
[267] Fix | Delete
*/
[268] Fix | Delete
GIT_EXTERN(int) git_remote_add_fetch(git_repository *repo, const char *remote, const char *refspec);
[269] Fix | Delete
[270] Fix | Delete
/**
[271] Fix | Delete
* Get the remote's list of fetch refspecs
[272] Fix | Delete
*
[273] Fix | Delete
* The memory is owned by the user and should be freed with
[274] Fix | Delete
* `git_strarray_free`.
[275] Fix | Delete
*
[276] Fix | Delete
* @param array pointer to the array in which to store the strings
[277] Fix | Delete
* @param remote the remote to query
[278] Fix | Delete
*/
[279] Fix | Delete
GIT_EXTERN(int) git_remote_get_fetch_refspecs(git_strarray *array, const git_remote *remote);
[280] Fix | Delete
[281] Fix | Delete
/**
[282] Fix | Delete
* Add a push refspec to the remote's configuration
[283] Fix | Delete
*
[284] Fix | Delete
* Add the given refspec to the push list in the configuration. No
[285] Fix | Delete
* loaded remote instances will be affected.
[286] Fix | Delete
*
[287] Fix | Delete
* @param repo the repository in which to change the configuration
[288] Fix | Delete
* @param remote the name of the remote to change
[289] Fix | Delete
* @param refspec the new push refspec
[290] Fix | Delete
* @return 0, GIT_EINVALIDSPEC if refspec is invalid or an error value
[291] Fix | Delete
*/
[292] Fix | Delete
GIT_EXTERN(int) git_remote_add_push(git_repository *repo, const char *remote, const char *refspec);
[293] Fix | Delete
[294] Fix | Delete
/**
[295] Fix | Delete
* Get the remote's list of push refspecs
[296] Fix | Delete
*
[297] Fix | Delete
* The memory is owned by the user and should be freed with
[298] Fix | Delete
* `git_strarray_free`.
[299] Fix | Delete
*
[300] Fix | Delete
* @param array pointer to the array in which to store the strings
[301] Fix | Delete
* @param remote the remote to query
[302] Fix | Delete
*/
[303] Fix | Delete
GIT_EXTERN(int) git_remote_get_push_refspecs(git_strarray *array, const git_remote *remote);
[304] Fix | Delete
[305] Fix | Delete
/**
[306] Fix | Delete
* Get the number of refspecs for a remote
[307] Fix | Delete
*
[308] Fix | Delete
* @param remote the remote
[309] Fix | Delete
* @return the amount of refspecs configured in this remote
[310] Fix | Delete
*/
[311] Fix | Delete
GIT_EXTERN(size_t) git_remote_refspec_count(const git_remote *remote);
[312] Fix | Delete
[313] Fix | Delete
/**
[314] Fix | Delete
* Get a refspec from the remote
[315] Fix | Delete
*
[316] Fix | Delete
* @param remote the remote to query
[317] Fix | Delete
* @param n the refspec to get
[318] Fix | Delete
* @return the nth refspec
[319] Fix | Delete
*/
[320] Fix | Delete
GIT_EXTERN(const git_refspec *)git_remote_get_refspec(const git_remote *remote, size_t n);
[321] Fix | Delete
[322] Fix | Delete
/**
[323] Fix | Delete
* Open a connection to a remote
[324] Fix | Delete
*
[325] Fix | Delete
* The transport is selected based on the URL. The direction argument
[326] Fix | Delete
* is due to a limitation of the git protocol (over TCP or SSH) which
[327] Fix | Delete
* starts up a specific binary which can only do the one or the other.
[328] Fix | Delete
*
[329] Fix | Delete
* @param remote the remote to connect to
[330] Fix | Delete
* @param direction GIT_DIRECTION_FETCH if you want to fetch or
[331] Fix | Delete
* GIT_DIRECTION_PUSH if you want to push
[332] Fix | Delete
* @param callbacks the callbacks to use for this connection
[333] Fix | Delete
* @param proxy_opts proxy settings
[334] Fix | Delete
* @param custom_headers extra HTTP headers to use in this connection
[335] Fix | Delete
* @return 0 or an error code
[336] Fix | Delete
*/
[337] Fix | Delete
GIT_EXTERN(int) git_remote_connect(git_remote *remote, git_direction direction, const git_remote_callbacks *callbacks, const git_proxy_options *proxy_opts, const git_strarray *custom_headers);
[338] Fix | Delete
[339] Fix | Delete
/**
[340] Fix | Delete
* Get the remote repository's reference advertisement list
[341] Fix | Delete
*
[342] Fix | Delete
* Get the list of references with which the server responds to a new
[343] Fix | Delete
* connection.
[344] Fix | Delete
*
[345] Fix | Delete
* The remote (or more exactly its transport) must have connected to
[346] Fix | Delete
* the remote repository. This list is available as soon as the
[347] Fix | Delete
* connection to the remote is initiated and it remains available
[348] Fix | Delete
* after disconnecting.
[349] Fix | Delete
*
[350] Fix | Delete
* The memory belongs to the remote. The pointer will be valid as long
[351] Fix | Delete
* as a new connection is not initiated, but it is recommended that
[352] Fix | Delete
* you make a copy in order to make use of the data.
[353] Fix | Delete
*
[354] Fix | Delete
* @param out pointer to the array
[355] Fix | Delete
* @param size the number of remote heads
[356] Fix | Delete
* @param remote the remote
[357] Fix | Delete
* @return 0 on success, or an error code
[358] Fix | Delete
*/
[359] Fix | Delete
GIT_EXTERN(int) git_remote_ls(const git_remote_head ***out, size_t *size, git_remote *remote);
[360] Fix | Delete
[361] Fix | Delete
/**
[362] Fix | Delete
* Check whether the remote is connected
[363] Fix | Delete
*
[364] Fix | Delete
* Check whether the remote's underlying transport is connected to the
[365] Fix | Delete
* remote host.
[366] Fix | Delete
*
[367] Fix | Delete
* @param remote the remote
[368] Fix | Delete
* @return 1 if it's connected, 0 otherwise.
[369] Fix | Delete
*/
[370] Fix | Delete
GIT_EXTERN(int) git_remote_connected(const git_remote *remote);
[371] Fix | Delete
[372] Fix | Delete
/**
[373] Fix | Delete
* Cancel the operation
[374] Fix | Delete
*
[375] Fix | Delete
* At certain points in its operation, the network code checks whether
[376] Fix | Delete
* the operation has been cancelled and if so stops the operation.
[377] Fix | Delete
*
[378] Fix | Delete
* @param remote the remote
[379] Fix | Delete
* @return 0 on success, or an error code
[380] Fix | Delete
*/
[381] Fix | Delete
GIT_EXTERN(int) git_remote_stop(git_remote *remote);
[382] Fix | Delete
[383] Fix | Delete
/**
[384] Fix | Delete
* Disconnect from the remote
[385] Fix | Delete
*
[386] Fix | Delete
* Close the connection to the remote.
[387] Fix | Delete
*
[388] Fix | Delete
* @param remote the remote to disconnect from
[389] Fix | Delete
* @return 0 on success, or an error code
[390] Fix | Delete
*/
[391] Fix | Delete
GIT_EXTERN(int) git_remote_disconnect(git_remote *remote);
[392] Fix | Delete
[393] Fix | Delete
/**
[394] Fix | Delete
* Free the memory associated with a remote
[395] Fix | Delete
*
[396] Fix | Delete
* This also disconnects from the remote, if the connection
[397] Fix | Delete
* has not been closed yet (using git_remote_disconnect).
[398] Fix | Delete
*
[399] Fix | Delete
* @param remote the remote to free
[400] Fix | Delete
*/
[401] Fix | Delete
GIT_EXTERN(void) git_remote_free(git_remote *remote);
[402] Fix | Delete
[403] Fix | Delete
/**
[404] Fix | Delete
* Get a list of the configured remotes for a repo
[405] Fix | Delete
*
[406] Fix | Delete
* The string array must be freed by the user.
[407] Fix | Delete
*
[408] Fix | Delete
* @param out a string array which receives the names of the remotes
[409] Fix | Delete
* @param repo the repository to query
[410] Fix | Delete
* @return 0 or an error code
[411] Fix | Delete
*/
[412] Fix | Delete
GIT_EXTERN(int) git_remote_list(git_strarray *out, git_repository *repo);
[413] Fix | Delete
[414] Fix | Delete
/**
[415] Fix | Delete
* Argument to the completion callback which tells it which operation
[416] Fix | Delete
* finished.
[417] Fix | Delete
*/
[418] Fix | Delete
typedef enum git_remote_completion_t {
[419] Fix | Delete
GIT_REMOTE_COMPLETION_DOWNLOAD,
[420] Fix | Delete
GIT_REMOTE_COMPLETION_INDEXING,
[421] Fix | Delete
GIT_REMOTE_COMPLETION_ERROR,
[422] Fix | Delete
} git_remote_completion_t;
[423] Fix | Delete
[424] Fix | Delete
/** Push network progress notification function */
[425] Fix | Delete
typedef int GIT_CALLBACK(git_push_transfer_progress_cb)(
[426] Fix | Delete
unsigned int current,
[427] Fix | Delete
unsigned int total,
[428] Fix | Delete
size_t bytes,
[429] Fix | Delete
void* payload);
[430] Fix | Delete
[431] Fix | Delete
/**
[432] Fix | Delete
* Represents an update which will be performed on the remote during push
[433] Fix | Delete
*/
[434] Fix | Delete
typedef struct {
[435] Fix | Delete
/**
[436] Fix | Delete
* The source name of the reference
[437] Fix | Delete
*/
[438] Fix | Delete
char *src_refname;
[439] Fix | Delete
/**
[440] Fix | Delete
* The name of the reference to update on the server
[441] Fix | Delete
*/
[442] Fix | Delete
char *dst_refname;
[443] Fix | Delete
/**
[444] Fix | Delete
* The current target of the reference
[445] Fix | Delete
*/
[446] Fix | Delete
git_oid src;
[447] Fix | Delete
/**
[448] Fix | Delete
* The new target for the reference
[449] Fix | Delete
*/
[450] Fix | Delete
git_oid dst;
[451] Fix | Delete
} git_push_update;
[452] Fix | Delete
[453] Fix | Delete
/**
[454] Fix | Delete
* Callback used to inform of upcoming updates.
[455] Fix | Delete
*
[456] Fix | Delete
* @param updates an array containing the updates which will be sent
[457] Fix | Delete
* as commands to the destination.
[458] Fix | Delete
* @param len number of elements in `updates`
[459] Fix | Delete
* @param payload Payload provided by the caller
[460] Fix | Delete
*/
[461] Fix | Delete
typedef int GIT_CALLBACK(git_push_negotiation)(const git_push_update **updates, size_t len, void *payload);
[462] Fix | Delete
[463] Fix | Delete
/**
[464] Fix | Delete
* Callback used to inform of the update status from the remote.
[465] Fix | Delete
*
[466] Fix | Delete
* Called for each updated reference on push. If `status` is
[467] Fix | Delete
* not `NULL`, the update was rejected by the remote server
[468] Fix | Delete
* and `status` contains the reason given.
[469] Fix | Delete
*
[470] Fix | Delete
* @param refname refname specifying to the remote ref
[471] Fix | Delete
* @param status status message sent from the remote
[472] Fix | Delete
* @param data data provided by the caller
[473] Fix | Delete
* @return 0 on success, otherwise an error
[474] Fix | Delete
*/
[475] Fix | Delete
typedef int GIT_CALLBACK(git_push_update_reference_cb)(const char *refname, const char *status, void *data);
[476] Fix | Delete
[477] Fix | Delete
/**
[478] Fix | Delete
* Callback to resolve URLs before connecting to remote
[479] Fix | Delete
*
[480] Fix | Delete
* If you return GIT_PASSTHROUGH, you don't need to write anything to
[481] Fix | Delete
* url_resolved.
[482] Fix | Delete
*
[483] Fix | Delete
* @param url_resolved The buffer to write the resolved URL to
[484] Fix | Delete
* @param url The URL to resolve
[485] Fix | Delete
* @param direction GIT_DIRECTION_FETCH or GIT_DIRECTION_PUSH
[486] Fix | Delete
* @param payload Payload provided by the caller
[487] Fix | Delete
* @return 0 on success, GIT_PASSTHROUGH or an error
[488] Fix | Delete
*/
[489] Fix | Delete
typedef int GIT_CALLBACK(git_url_resolve_cb)(git_buf *url_resolved, const char *url, int direction, void *payload);
[490] Fix | Delete
[491] Fix | Delete
/**
[492] Fix | Delete
* The callback settings structure
[493] Fix | Delete
*
[494] Fix | Delete
* Set the callbacks to be called by the remote when informing the user
[495] Fix | Delete
* about the progress of the network operations.
[496] Fix | Delete
*/
[497] Fix | Delete
struct git_remote_callbacks {
[498] Fix | Delete
unsigned int version; /**< The version */
[499] Fix | Delete
12
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function