From b24e6047a8da3cddfd686e6a9157ed4bac28ed4f Mon Sep 17 00:00:00 2001 From: Chris Rorvick Date: Thu, 29 Nov 2012 19:41:34 -0600 Subject: push: add advice for rejected tag reference Advising the user to fetch and merge only makes sense if the rejected reference is a branch. If none of the rejections are for branches, just tell the user the reference already exists. Signed-off-by: Chris Rorvick Signed-off-by: Junio C Hamano --- transport.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'transport.c') diff --git a/transport.c b/transport.c index d4568e7b3..bc31e8e66 100644 --- a/transport.c +++ b/transport.c @@ -740,6 +740,8 @@ void transport_print_push_status(const char *dest, struct ref *refs, ref->status != REF_STATUS_OK) n += print_one_push_status(ref, dest, n, porcelain); if (ref->status == REF_STATUS_REJECT_NONFASTFORWARD) { + if (ref->not_forwardable) + *reject_reasons |= REJECT_ALREADY_EXISTS; if (!strcmp(head, ref->name)) *reject_reasons |= REJECT_NON_FF_HEAD; else -- cgit v1.2.1