Add uploadpack configuration info to remote.
Signed-off-by: Daniel Barkalow <barkalow@iabervon.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Daniel Barkalow committed
Sep 10, 2007 at 23:02 UTC
0012ba2108aa42947dedf19f3db2de73a67cc4f5
2 files changed
+6
remote.c
+5
@@ -196,6 +196,11 @@ static int handle_config(const char *key, const char *value)
196
remote->receivepack = xstrdup(value);
197
else
198
error("more than one receivepack given, using the first");
199
+ } else if (!strcmp(subkey, ".uploadpack")) {
200
+ if (!remote->uploadpack)
201
+ remote->uploadpack = xstrdup(value);
202
+ else
203
+ error("more than one uploadpack given, using the first");
204
}
205
return 0;
206
}
remote.h
+1
@@ -16,6 +16,7 @@ struct remote {
16
int fetch_refspec_nr;
17
18
const char *receivepack;
19
+ const char *uploadpack;
20
};
21
22
struct remote *remote_get(const char *name);