]> git.draconx.ca Git - zshconf.git/blobdiff - zshrc
Fix prompt colouring when using SSH, broken by last commit.
[zshconf.git] / zshrc
diff --git a/zshrc b/zshrc
index 130e70c1c192ecef3b3097a8d09fa3cebc6aa41b..67e8f47a133093dcdd5a531fcf93ddb81d90d625 100644 (file)
--- a/zshrc
+++ b/zshrc
@@ -59,15 +59,23 @@ preexec() {
        __NEWRUN=yes
 }
 
-if [ -n "$COLORTERM" ]; then
-       PS1=$'%(!,%{\e[31;1m%},%{\e[32;1m%}%n@)%m%{\e[34;1m%} %33<...<%~%<< %#%{\e[0m%} '
+# A gentoo-like prompt.
+PS1=$'%B%(!,%F{red},%F{green}%n@)%m %F{blue}%33<...<%~%<< %#%f%b '
 
+if [ -n "$COLORTERM" ]; then
        # Random colour-related options
        export MINICOM="-c on"
-else
-       PS1='%n@%m %33<...<%~%<< %# '
 fi
 
 if [[ -n "$SSH_CONNECTION" ]]; then
-       PS1="${PS1/\[32/[33}"
+       PS1="${PS1/green/yellow}"
 fi
+
+# I like colours
+alias ls='ls --color=auto'
+alias grep='grep --color=auto'
+
+# I hate mistakes
+alias mv='mv -i'
+alias rm='rm -i'
+alias cp='cp -i'