diff options
| author | Vicent Martà <vicent@github.com> | 2012-11-01 09:15:29 -0700 |
|---|---|---|
| committer | Vicent Martà <vicent@github.com> | 2012-11-01 09:15:29 -0700 |
| commit | 7ae73e94dbbb4249f26dd5d0a21d25e1dc4667ca (patch) | |
| tree | 167eecfed309accc2b2e5568c13ec3f715cb46b5 /include/git2/remote.h | |
| parent | 003808b38cd09dab8748f93bb44a0df9aca6820c (diff) | |
| parent | ff830366ea611c9285a23432edebc16ff6a3d436 (diff) | |
| download | libgit2-7ae73e94dbbb4249f26dd5d0a21d25e1dc4667ca.tar.gz | |
Merge pull request #1030 from pwkelley/transports
Reorganize transport architecture
Diffstat (limited to 'include/git2/remote.h')
| -rw-r--r-- | include/git2/remote.h | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/include/git2/remote.h b/include/git2/remote.h index ad5c38902..1827e12b0 100644 --- a/include/git2/remote.h +++ b/include/git2/remote.h @@ -13,6 +13,7 @@ #include "net.h" #include "indexer.h" #include "strarray.h" +#include "transport.h" /** * @file git2/remote.h @@ -283,10 +284,22 @@ GIT_EXTERN(int) git_remote_add(git_remote **out, git_repository *repo, const cha * @param remote the remote to configure * @param check whether to check the server's certificate (defaults to yes) */ - GIT_EXTERN(void) git_remote_check_cert(git_remote *remote, int check); /** + * Sets a custom transport for the remote. The caller can use this function + * to bypass the automatic discovery of a transport by URL scheme (i.e. + * http://, https://, git://) and supply their own transport to be used + * instead. After providing the transport to a remote using this function, + * the transport object belongs exclusively to that remote, and the remote will + * free it when it is freed with git_remote_free. + * + * @param remote the remote to configure + * @param transport the transport object for the remote to use + */ +GIT_EXTERN(int) git_remote_set_transport(git_remote *remote, git_transport *transport); + +/** * Argument to the completion callback which tells it which operation * finished. */ |
