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

Re: [PATCH] Makes 'git-stash show' stay quiet when there are no stashes.

From: Junio C Hamano <hidden>
Date: 2016-06-15 22:43:59

Possibly related (same subject, not in this thread)

Jing Xue [off-list ref] writes:
(I tried to send this trivial patch for a couple of times using
git-send-email, but somehow it never turned up.)

Currently when there are no stashes, 'git stash show' basically aborts with an
error message from rev-parse: "fatal: Needed a single revision", which can be
confusing. This patch makes git-stash keep quiet and exit gracefully in that
case.
I agree "git stash show" should not give cryptic error message, but I
think you should do this only when the user did not explicitly say which
stash to show (that is, we should still give error message if the user
said "git stash show garbage").
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help