Previously, git stash show would accept stash-like arguments, but only if there was a stash on the stack. Now, git stash accepts stash-like arguments always and only fails if no stash-like argument is specified and there is no stash stack. Signed-off-by: Jon Seymour <jon.seymour@xxxxxxxxx> --- git-stash.sh | 9 +++++++-- 1 files changed, 7 insertions(+), 2 deletions(-) diff --git a/git-stash.sh b/git-stash.sh index 97e3749..5b875ea 100755 --- a/git-stash.sh +++ b/git-stash.sh @@ -210,14 +210,19 @@ list_stash () { } show_stash () { - have_stash || die 'No stash found' - flags=$(git rev-parse --no-revs --flags "$@") if test -z "$flags" then flags=--stat fi + revs=$(git rev-parse --revs-only "$@") + if test -z "$revs" + then + have_stash || die "No stash found" + set -- ${ref_stash}@{0} + fi + assert_stash_like "$@" git diff $flags $b_commit $w_commit -- 1.7.2.1.51.g82c0c0 -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html