diff options
author | Ronan Amicel <ronan.amicel@gmail.com> | 2012-01-04 12:20:30 +0100 |
---|---|---|
committer | Ronan Amicel <ronan.amicel@gmail.com> | 2012-01-04 12:20:30 +0100 |
commit | 3a9d158cc9f413591263738e08f1f5a10c627a48 (patch) | |
tree | ff5fb5de3d5238415839048688706dfcf245feda | |
parent | Fixed Mercurial repository detection (diff) | |
download | git-prompt-3a9d158cc9f413591263738e08f1f5a10c627a48.tar.gz git-prompt-3a9d158cc9f413591263738e08f1f5a10c627a48.tar.bz2 git-prompt-3a9d158cc9f413591263738e08f1f5a10c627a48.zip |
Show current bookmark in Mercurial
-rwxr-xr-x | git-prompt.sh | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/git-prompt.sh b/git-prompt.sh index a63830b..d71d9b4 100755 --- a/git-prompt.sh +++ b/git-prompt.sh @@ -393,8 +393,13 @@ parse_hg_status() { branch=`hg branch 2> /dev/null` + [[ -f $hg_root/.hg/bookmarks.current ]] && bookmark=`cat "$hg_root/.hg/bookmarks.current"` + [[ -z $modified ]] && [[ -z $untracked ]] && [[ -z $added ]] && clean=clean vcs_info=${branch/default/D} + if [[ "$bookmark" ]] ; then + vcs_info+=/$bookmark + fi } |