From 58b69ddf5d918506a14c53d968e88f205c8c936a Mon Sep 17 00:00:00 2001 From: Michael Sena Date: Wed, 12 Aug 2015 09:56:42 +1000 Subject: [PATCH] Added a function to the core GIT library that enables Cygwin users to display GIT information in a fork-friendly manner. --- lib/git.zsh | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/lib/git.zsh b/lib/git.zsh index 118841f06..ab09719da 100644 --- a/lib/git.zsh +++ b/lib/git.zsh @@ -7,6 +7,13 @@ function git_prompt_info() { fi } +function git_cygwin_prompt_info_quick() { + ref=$(command git symbolic-ref -q --short HEAD 2> /dev/null) + if [[ "${ref}" != "" ]]; then + echo "git:${ref}" + fi +} + # Checks if working tree is dirty parse_git_dirty() {