summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStefan Ritter <xeno@thehappy.de>2010-08-10 00:24:10 +0200
committerStefan Ritter <xeno@thehappy.de>2010-08-10 00:24:10 +0200
commitade829d5ba4f96c401152e8d46fefc5bca0d22cc (patch)
treeaf24fa9f7dcdc7ad4745bc6230af3d26c5250108
parentd805ab93fabb59c6a9f7731bd313c56b64dd92a8 (diff)
Add vcs_info to prompt
-rw-r--r--zsh/zshrc8
1 files changed, 7 insertions, 1 deletions
diff --git a/zsh/zshrc b/zsh/zshrc
index 01b6098..a06a633 100644
--- a/zsh/zshrc
+++ b/zsh/zshrc
@@ -9,7 +9,7 @@
#PROMPT="$PUSER$PATKI$PHOST$PDOPP$PPATH$PCOMM "
-PROMPT="%~ %% "
+PROMPT="%~%(1v.%F{green}%1v%f.) %% "
zstyle ':completion:*' special-dirs true
zstyle ':completion:*:*:kill:*' menu yes select
@@ -33,6 +33,12 @@ HISTFILE=~/.zsh_history
autoload -U compinit; compinit
autoload zmv
+autoload -Uz vcs_info
+precmd() {
+ psvar=()
+ vcs_info
+ [[ -n $vcs_info_msg_0_ ]] && psvar[1]="$vcs_info_msg_0_"
+}
alias c="clear && fortune"