From 391c53bdcd7bbce366eaef7288afb948525ed3e8 Mon Sep 17 00:00:00 2001 From: Thomas Rast Date: Mon, 19 Oct 2009 17:48:11 +0200 Subject: [PATCH] stash list: use new %g formats instead of sed With the new formats, we can rewrite 'git stash list' in terms of an appropriate pretty format, instead of hand-editing with sed. This has the advantage that it obeys the normal settings for git-log, notably the pager. Signed-off-by: Thomas Rast Signed-off-by: Junio C Hamano --- git-stash.sh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/git-stash.sh b/git-stash.sh index 4febbbfa5d..f8847c1fc0 100755 --- a/git-stash.sh +++ b/git-stash.sh @@ -205,8 +205,7 @@ have_stash () { list_stash () { have_stash || return 0 - git log --no-color --pretty=oneline -g "$@" $ref_stash -- | - sed -n -e 's/^[.0-9a-f]* refs\///p' + git log --format="%gd: %gs" -g "$@" $ref_stash -- } show_stash () { -- 2.11.4.GIT