Permalink
Browse files

Modification to the frisk theme to work with the BZR lib

  • Loading branch information...
1 parent e30a124 commit efc37c1f715eb77be5f30411fa36589727643126 @prubianes prubianes committed Nov 6, 2013
Showing with 10 additions and 0 deletions.
  1. +10 −0 lib/bzr.zsh
View
@@ -0,0 +1,10 @@
+## Bazaar integration
+## Just works with the GIT integration just add $(bzr_prompt_info) to the PROMPT
+function bzr_prompt_info() {
+ BZR_CB=`bzr nick 2> /dev/null | grep -v "ERROR" | cut -d ":" -f2 | awk -F / '{print "bzr::"$1}'`
+ if [ -n "$BZR_CB" ]; then
+ BZR_DIRTY=""
+ [[ -n `bzr status` ]] && BZR_DIRTY=" %{$fg[red]%} * %{$fg[green]%}"
+ echo "$ZSH_THEME_SCM_PROMPT_PREFIX$BZR_CB$BZR_DIRTY$ZSH_THEME_GIT_PROMPT_SUFFIX"
+ fi
+}

0 comments on commit efc37c1

Please sign in to comment.