summaryrefslogtreecommitdiff
path: root/builtin-remote.c
diff options
context:
space:
mode:
authorLibravatar Junio C Hamano <gitster@pobox.com>2008-05-05 19:15:39 -0700
committerLibravatar Junio C Hamano <gitster@pobox.com>2008-05-05 19:15:39 -0700
commitdc484f2213a34ced5abe5eb968650035204b6035 (patch)
tree1e1d0d7563cc91bd52ffcb895b9f21a0ed2607c8 /builtin-remote.c
parentpost-merge: Add it's not executed if merge failed. (diff)
parentAdd a remote.*.mirror configuration option (diff)
downloadtgif-dc484f2213a34ced5abe5eb968650035204b6035.tar.xz
Merge branch 'pb/remote-mirror-config'
* pb/remote-mirror-config: Add a remote.*.mirror configuration option
Diffstat (limited to 'builtin-remote.c')
-rw-r--r--builtin-remote.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/builtin-remote.c b/builtin-remote.c
index 93bb84e1d4..8b63619ef0 100644
--- a/builtin-remote.c
+++ b/builtin-remote.c
@@ -118,6 +118,13 @@ static int add(int argc, const char **argv)
return 1;
}
+ if (mirror) {
+ strbuf_reset(&buf);
+ strbuf_addf(&buf, "remote.%s.mirror", name);
+ if (git_config_set(buf.buf, "yes"))
+ return 1;
+ }
+
if (fetch && fetch_remote(name))
return 1;