git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Align git push stderr output to the same as git pull
@ 2014-07-10  5:33 Sam McLeod
  2014-07-10 20:50 ` Jeff King
  0 siblings, 1 reply; 2+ messages in thread
From: Sam McLeod @ 2014-07-10  5:33 UTC (permalink / raw)
  To: git

[-- Attachment #1: Type: text/plain, Size: 1300 bytes --]

As per: https://github.com/git/git/pull/100

'For already up-to-date repos return "Already up-to-date" which is the
same message git pull returns.'

Developer's Certificate of Origin 1.1

By making a contribution to this project, I certify that:

(a) The contribution was created in whole or in part by me and I
  have the right to submit it under the open source license
  indicated in the file; or

(b) The contribution is based upon previous work that, to the best
  of my knowledge, is covered under an appropriate open source
  license and I have the right under that license to submit that
  work with modifications, whether created in whole or in part
  by me, under the same open source license (unless I am
  permitted to submit under a different license), as indicated
  in the file; or

(c) The contribution was provided directly to me by some other
  person who certified (a), (b) or (c) and I have not modified
  it.

(d) I understand and agree that this project and the contribution
  are public and that a record of the contribution (including all
  personal information I submit with it, including my sign-off) is
  maintained indefinitely and may be redistributed consistent with
  this project or the open source license(s) involved.

  Signed-off-by: Sam McLeod <sammcj@gmail.com>

[-- Attachment #2: git-push-stderr.patch --]
[-- Type: application/octet-stream, Size: 796 bytes --]

diff --git a/builtin/send-pack.c b/builtin/send-pack.c
index f420b74..6fb2642 100644
--- a/builtin/send-pack.c
+++ b/builtin/send-pack.c
@@ -274,7 +274,7 @@ int cmd_send_pack(int argc, const char **argv, const char *prefix)
 	}
 
 	if (!ret && !transport_refs_pushed(remote_refs))
-		fprintf(stderr, "Everything up-to-date\n");
+		fprintf(stderr, "Already up-to-date\n");
 
 	return ret;
 }
diff --git a/transport.c b/transport.c
index 59c9727..4dd9f74 100644
--- a/transport.c
+++ b/transport.c
@@ -1220,7 +1220,7 @@ int transport_push(struct transport *transport,
 		if (porcelain && !push_ret)
 			puts("Done");
 		else if (!quiet && !ret && !transport_refs_pushed(remote_refs))
-			fprintf(stderr, "Everything up-to-date\n");
+			fprintf(stderr, "Already up-to-date\n");
 
 		return ret;
 	}

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: Align git push stderr output to the same as git pull
  2014-07-10  5:33 Align git push stderr output to the same as git pull Sam McLeod
@ 2014-07-10 20:50 ` Jeff King
  0 siblings, 0 replies; 2+ messages in thread
From: Jeff King @ 2014-07-10 20:50 UTC (permalink / raw)
  To: Sam McLeod; +Cc: git

On Thu, Jul 10, 2014 at 03:33:47PM +1000, Sam McLeod wrote:

> 'For already up-to-date repos return "Already up-to-date" which is the
> same message git pull returns.'

Please send your patches inline as a single body part, as generated by
"git format-patch" (you can use git-send-email to send).

> Developer's Certificate of Origin 1.1

You can drop the DCO here. Your Signed-off-by line is enough.

> diff --git a/builtin/send-pack.c b/builtin/send-pack.c
> index f420b74..6fb2642 100644
> --- a/builtin/send-pack.c
> +++ b/builtin/send-pack.c
> @@ -274,7 +274,7 @@ int cmd_send_pack(int argc, const char **argv, const char *prefix)
>  	}
>  
>  	if (!ret && !transport_refs_pushed(remote_refs))
> -		fprintf(stderr, "Everything up-to-date\n");
> +		fprintf(stderr, "Already up-to-date\n");

Hrm. So this makes things consistent with git-pull, but despite the
names, push and pull are not actually opposites. Push and fetch are
opposites. And fetch does not say anything in the up-to-date case.

So I'd somewhat wonder whether we should just be making "push" less
chatty here. Still, that is a much bigger change that some people might
disagree with, and I confess I don't care overly (but nor did the
Everything/Already ever bother me either :) ).

-Peff

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2014-07-10 20:50 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-07-10  5:33 Align git push stderr output to the same as git pull Sam McLeod
2014-07-10 20:50 ` Jeff King

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).