* [PATCH v2] bash: Match lightweight tags in prompt
@ 2010-12-01 13:17 knittl
2010-12-01 19:53 ` Junio C Hamano
0 siblings, 1 reply; 2+ messages in thread
From: knittl @ 2010-12-01 13:17 UTC (permalink / raw)
To: git, Shawn Pearce
>From 6be63c5bc1a411a13a012a6508a7301bed7faec6 Mon Sep 17 00:00:00 2001
From: Daniel Knittl-Frank <knittl89+git@googlemail.com>
Date: Fri, 19 Nov 2010 16:40:02 +0100
Subject: [PATCH] bash: Match lightweight tags in prompt
the bash prompt would display a commit's SHA1 when having checked out a
lightweight tag. provide `--tags` to `git describe` in the completion
script, so it will display lightweight tag names (as it already does for
annotated tags)
Signed-off-by: Daniel Knittl-Frank <knittl89+git@googlemail.com>
---
version two of my patch, adding the missing s-o-b and extending commit message
the diff is still the same as v1
contrib/completion/git-completion.bash | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/contrib/completion/git-completion.bash
b/contrib/completion/git-completion.bash
index f710469..604fa79 100755
--- a/contrib/completion/git-completion.bash
+++ b/contrib/completion/git-completion.bash
@@ -261,7 +261,7 @@ __git_ps1 ()
(describe)
git describe HEAD ;;
(* | default)
- git describe --exact-match HEAD ;;
+ git describe --tags --exact-match HEAD ;;
esac 2>/dev/null)" ||
b="$(cut -c1-7 "$g/HEAD" 2>/dev/null)..." ||
--
1.7.3.2.334.gd1031
--
typed with http://neo-layout.org
myFtPhp -- visit http://myftphp.sf.net -- v. 0.4.7 released!
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH v2] bash: Match lightweight tags in prompt
2010-12-01 13:17 [PATCH v2] bash: Match lightweight tags in prompt knittl
@ 2010-12-01 19:53 ` Junio C Hamano
0 siblings, 0 replies; 2+ messages in thread
From: Junio C Hamano @ 2010-12-01 19:53 UTC (permalink / raw)
To: knittl; +Cc: git, Shawn Pearce
knittl <knittl89@googlemail.com> writes:
> From 6be63c5bc1a411a13a012a6508a7301bed7faec6 Mon Sep 17 00:00:00 2001
> From: Daniel Knittl-Frank <knittl89+git@googlemail.com>
> Date: Fri, 19 Nov 2010 16:40:02 +0100
> Subject: [PATCH] bash: Match lightweight tags in prompt
Please drop these lines next time, so that I do not have to remove them in
my editor before applying.
> the bash prompt would display a commit's SHA1 when having checked out a
> lightweight tag. provide `--tags` to `git describe` in the completion
> script, so it will display lightweight tag names (as it already does for
> annotated tags)
Hmph. Is your Shift-key broken (probably not, as you spelled SHA in
capital)?
> Signed-off-by: Daniel Knittl-Frank <knittl89+git@googlemail.com>
> ---
> version two of my patch, adding the missing s-o-b and extending commit message
>
> the diff is still the same as v1
Thanks; will apply (no need for resend).
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2010-12-01 19:54 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-12-01 13:17 [PATCH v2] bash: Match lightweight tags in prompt knittl
2010-12-01 19:53 ` Junio C Hamano
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.