diff options
author | Felipe Contreras <felipe.contreras@gmail.com> | 2013-11-12 14:56:56 -0600 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2013-11-12 13:34:32 -0800 |
commit | 510fa6f5188d715050899eee221c739f1c0a8b12 (patch) | |
tree | 8c0e297298060f5ae0e1d0b96f35b6fcc89e6529 /transport-helper.c | |
parent | 5a75353fe381b344a33d7a89f7803e4a24d2ddcf (diff) | |
download | git-510fa6f5188d715050899eee221c739f1c0a8b12.tar.gz |
transport-helper: add 'force' to 'export' helpers
Otherwise they cannot know when to force the push or not (other than
hacks).
Tests-by: Richard Hansen <rhansen@bbn.com>
Documentation-by: Richard Hansen <rhansen@bbn.com>
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'transport-helper.c')
-rw-r--r-- | transport-helper.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/transport-helper.c b/transport-helper.c index d05fc7c276..bcf5469bcc 100644 --- a/transport-helper.c +++ b/transport-helper.c @@ -854,6 +854,11 @@ static int push_refs_with_export(struct transport *transport, die("helper %s does not support dry-run", data->name); } + if (flags & TRANSPORT_PUSH_FORCE) { + if (set_helper_option(transport, "force", "true") != 0) + warning("helper %s does not support 'force'", data->name); + } + helper = get_helper(transport); write_constant(helper->in, "export\n"); |