git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] Eliminate redirection to stdout and stderr when quiet option is available

From
Junio C Hamano <gitster@pobox.com>
Date
May 14, 2009, 07:27 UTC
Message-ID
<7vzldgw3dz.fsf@alter.siamese.dyndns.org>
In-Reply-To
<6f5a4e780905140013g75d85558tfaa3c85430f8a8a3@mail.gmail.com>
Dan Loewenherz <daniel.loewenherz@yale.edu> writes:
Show 11 quoted lines
> diff --git a/git-add--interactive.perl b/git-add--interactive.perl
> index f6e536e..e1106c9 100755
> --- a/git-add--interactive.perl
> +++ b/git-add--interactive.perl
> @@ -158,7 +158,7 @@ my $status_head = sprintf($status_fmt, 'staged',
> 'unstaged', 'path');
>  {
>  	my $initial;
>  	sub is_initial_commit {
> -		$initial = system('git rev-parse HEAD -- >/dev/null 2>&1') != 0
> +		$initial = system('git rev-parse -q HEAD -- ') != 0
Isn't this conversion wrong?
	$ git rev-parse -q HEAD --
        95405ba6cf7adeaa4a066e8a3a1b76b73f7b9341
Show 10 quoted lines
> diff --git a/git-am.sh b/git-am.sh
> index 6d1848b..8a86d05 100755
> --- a/git-am.sh
> +++ b/git-am.sh
> @@ -36,7 +36,7 @@ cd_to_toplevel
>  git var GIT_COMMITTER_IDENT >/dev/null ||
>  	die "You need to set your committer info first"
>
> -if git rev-parse --verify -q HEAD >/dev/null
> +if git rev-parse --verify -q HEAD
Likewise.

Should I spend more time myself, or will you double check the patch and resubmit?

Previous: Dan LoewenherzNext: Johannes Schindelin
Message 2 of 4 in “Eliminate redirection to stdout and stderr when quiet option is available”
  1. Eliminate redirection to stdout and stderr when quiet option is availableDan Loewenherz, May 14, 2009
  2. Junio C HamanoMay 14, 2009
  3. Johannes SchindelinMay 14, 2009
  4. Dan LoewenherzMay 14, 2009

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.