Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/libgit2.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarlos Martín Nieto <cmn@dwim.me>2014-03-26 14:15:57 +0400
committerCarlos Martín Nieto <cmn@dwim.me>2014-04-01 15:38:04 +0400
commitfd536d29c127648abb2ce5f6f619135ce69b9800 (patch)
tree8113aac1ee75b94d8637ca8519a456b54c826900 /examples
parent77b699e0da3d4a4fed742893bd172f3ee7b936d5 (diff)
remote: rename inmemory to anonymous and swap url and fetch order
The order in this function is the opposite to what create_with_fetchspec() has, so change this one, as url-then-refspec is what git does. As we need to break compilation and the swap doesn't do that, let's take this opportunity to rename in-memory remotes to anonymous as that's really what sets them apart.
Diffstat (limited to 'examples')
-rw-r--r--examples/network/fetch.c2
-rw-r--r--examples/network/ls-remote.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/examples/network/fetch.c b/examples/network/fetch.c
index ad16f2793..fdd82a1f7 100644
--- a/examples/network/fetch.c
+++ b/examples/network/fetch.c
@@ -91,7 +91,7 @@ int fetch(git_repository *repo, int argc, char **argv)
// Figure out whether it's a named remote or a URL
printf("Fetching %s for repo %p\n", argv[1], repo);
if (git_remote_load(&remote, repo, argv[1]) < 0) {
- if (git_remote_create_inmemory(&remote, repo, NULL, argv[1]) < 0)
+ if (git_remote_create_anonymous(&remote, repo, argv[1], NULL) < 0)
return -1;
}
diff --git a/examples/network/ls-remote.c b/examples/network/ls-remote.c
index 1e08b293e..a5c14cea8 100644
--- a/examples/network/ls-remote.c
+++ b/examples/network/ls-remote.c
@@ -15,7 +15,7 @@ static int use_remote(git_repository *repo, char *name)
// Find the remote by name
error = git_remote_load(&remote, repo, name);
if (error < 0) {
- error = git_remote_create_inmemory(&remote, repo, NULL, name);
+ error = git_remote_create_anonymous(&remote, repo, name, NULL);
if (error < 0)
goto cleanup;
}