diff options
| author | Sascha Cunz <Sascha@BabbelBox.org> | 2012-07-25 01:33:15 +0200 |
|---|---|---|
| committer | Sascha Cunz <Sascha@BabbelBox.org> | 2012-07-26 23:08:22 +0200 |
| commit | 765015902ab346f4879acceaf8c8adf61f0e0ed5 (patch) | |
| tree | 67d101e2f2cd3b66ccac411ad2d83cff3c6522b8 /include/git2/remote.h | |
| parent | 3ed4b5012bbdba844ae1ffdff884a1eb630e9884 (diff) | |
| download | libgit2-765015902ab346f4879acceaf8c8adf61f0e0ed5.tar.gz | |
Remotes: Setter for url+pushurl; Getter for pushurl
Diffstat (limited to 'include/git2/remote.h')
| -rw-r--r-- | include/git2/remote.h | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/include/git2/remote.h b/include/git2/remote.h index 5c01949d2..6d4b6cc20 100644 --- a/include/git2/remote.h +++ b/include/git2/remote.h @@ -80,6 +80,36 @@ GIT_EXTERN(const char *) git_remote_name(git_remote *remote); GIT_EXTERN(const char *) git_remote_url(git_remote *remote); /** + * Get the remote's url for pushing + * + * @param remote the remote + * @return a pointer to the url or NULL if no special url for pushing is set + */ +GIT_EXTERN(const char *) git_remote_pushurl(git_remote *remote); + +/** + * Set the remote's url + * + * Existing connections will not be updated. + * + * @param remote the remote + * @param url the url to set + * @return 0 or an error value + */ +GIT_EXTERN(int) git_remote_set_url(git_remote *remote, const char* url); + +/** + * Set the remote's url for pushing + * + * Existing connections will not be updated. + * + * @param remote the remote + * @param url the url to set or NULL to clear the pushurl + * @return 0 or an error value + */ +GIT_EXTERN(int) git_remote_set_pushurl(git_remote *remote, const char* url); + +/** * Set the remote's fetch refspec * * @param remote the remote |
