Permalink
Browse files

Liquid theme (fork of gallois) added

  • Loading branch information...
1 parent 2617b62 commit 5f7ba09b7a801c8f62a0eacf1bc9ce0da8ba51dd @lucassmagal committed Oct 6, 2012
Showing with 29 additions and 0 deletions.
  1. +29 −0 themes/liquid.zsh-theme
View
@@ -0,0 +1,29 @@
+# This is a fork of gallois theme
+# Now it can show both git and hg branches
+# rvm is not shown
+# You should use git & mercurial plugins
+
+ZSH_THEME_GIT_PROMPT_PREFIX="%{$reset_color%}%{$fg[green]%}["
+ZSH_THEME_GIT_PROMPT_SUFFIX="]%{$reset_color%}"
+ZSH_THEME_GIT_PROMPT_DIRTY="%{$fg[red]%}*%{$reset_color%}"
+ZSH_THEME_GIT_PROMPT_CLEAN=""
+
+# Customized git status
+function git_custom_status {
+ local cb=$(current_branch)
+ if [ -n "$cb" ]; then
+ echo "$(parse_git_dirty)${ZSH_THEME_GIT_PROMPT_PREFIX}git:$(current_branch)$ZSH_THEME_GIT_PROMPT_SUFFIX"
+ fi
+}
+
+# Customized hg status
+function hg_custom_status {
+ local cb=$(hg_current_branch)
+ if [ -n "$cb" ]; then
+ echo "$(parse_hg_dirty)${ZSH_THEME_GIT_PROMPT_PREFIX}hg:$(hg_current_branch)$ZSH_THEME_GIT_PROMPT_SUFFIX"
+ fi
+}
+
+RPROMPT='$(git_custom_status)$(hg_custom_status)%{$reset_color%}'
+
+PROMPT='%{$fg[cyan]%}[%~% ]%(?.%{$fg[green]%}.%{$fg[red]%})%B$%b '

0 comments on commit 5f7ba09

Please sign in to comment.