Thread (2 messages) flat view 2 messages, 2 authors, 2016-06-15

Re: [PATCH] git stash: one bug and one feature request

From: Junio C Hamano <hidden>
Date: 2016-06-15 22:44:02

"Marco Costalba" [off-list ref] writes:
Otherwise git-stash is unusable by scripts that check
stderr to detect fail/success of launched command.
Sorry, but I happen to disagree with your notion of "having
something on stderr is an error" to begin with.  I think scripts
written that way are either simply bogus, or are working around
a defect in the underlying command it calls (perhaps it does not
signal error with exit status properly).

A command that produces machine parsable output should write
that out to stdout, and if it needs to emit other informational
messages meant for human consumption (this includes progress
bars), that should be sent to stderr so that scripts can get the
meat of the output without having to filter cruft out.

If the command does not signal an error by exiting with non-zero
status, that would be a bug indeed and you can fix that instead,
I think.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help