From: Tim Olsen <tim@brooklynpenguin.com>
To: git@vger.kernel.org
Subject: fatal output from git-show really wants a terminal
Date: Wed, 10 Dec 2008 11:01:49 -0500 [thread overview]
Message-ID: <ghop5d$qud$1@ger.gmane.org> (raw)
It appears that when outputting a fatal error, git-show will choose
stdout over stderr if stdout is a terminal and stderr is not. How do I
redirect the error but still allow stdout to be displayed?
~/git$ mkdir test
~/git$ cd test
~/git/test$ git init
~/git/test$ git show 12345
fatal: ambiguous argument '12345': unknown revision or path not in the
working tree.
Use '--' to separate paths from revisions
~/git/test$ git show 12345 2> /dev/null
fatal: ambiguous argument '12345': unknown revision or path not in the
working tree.
Use '--' to separate paths from revisions
~/git/test$ git show 12345 > /dev/null
fatal: ambiguous argument '12345': unknown revision or path not in the
working tree.
Use '--' to separate paths from revisions
~/git/test$ git show 12345 > /dev/null 2> /dev/null
~/git/test$ git show 12345 > /tmp/out 2> /tmp/err
~/git/test$ cat /tmp/out
~/git/test$ cat /tmp/err
fatal: ambiguous argument '12345': unknown revision or path not in the
working tree.
Use '--' to separate paths from revisions
next reply other threads:[~2008-12-10 16:03 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-12-10 16:01 Tim Olsen [this message]
2008-12-10 16:10 ` fatal output from git-show really wants a terminal Boyd Stephen Smith Jr.
2008-12-10 19:46 ` Johannes Sixt
2008-12-10 20:10 ` Tim Olsen
2008-12-10 22:24 ` Boyd Stephen Smith Jr.
[not found] ` <alpine.DEB.1.00.0812111015140.18321@eeepc-johanness>
2008-12-11 16:51 ` Boyd Stephen Smith Jr.
2008-12-11 21:55 ` Jeff King
2008-12-11 22:45 ` Boyd Stephen Smith Jr.
2008-12-11 22:59 ` Jeff King
2008-12-11 23:03 ` Junio C Hamano
2008-12-15 8:15 ` Junio C Hamano
2008-12-15 8:23 ` Junio C Hamano
2008-12-15 8:25 ` Jeff King
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='ghop5d$qud$1@ger.gmane.org' \
--to=tim@brooklynpenguin.com \
--cc=git@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.