prettified prompt
This commit is contained in:
12
zshrc
12
zshrc
@@ -3,6 +3,7 @@
|
||||
zstyle ':completion:*' completer _expand _complete _ignored _approximate
|
||||
zstyle ':completion:*' matcher-list 'm:{[:lower:][:upper:]}={[:upper:][:lower:]}' 'm:{[:lower:]}={[:upper:]}' 'r:|[._-_]=** r:|=**' ''
|
||||
zstyle :compinstall filename '/Users/veitheller/.zshrc'
|
||||
zle_highlight=(default:bold)
|
||||
|
||||
autoload -Uz compinit -D && compinit
|
||||
autoload -U promptinit && promptinit
|
||||
@@ -69,7 +70,6 @@ alias dud="du -d 1"
|
||||
alias loc="cloc --read-lang-def=/Users/veitheller/.scripts/cloc-z.txt *"
|
||||
alias ls="ls -a"
|
||||
alias quit="exit"
|
||||
#alias exit="killall tmux"
|
||||
alias howmuch="git ls-tree -r -z --name-only HEAD -- . | xargs -0 -n1 git blame --line-porcelain HEAD | grep '^author '| sort | uniq -c | sort -nr"
|
||||
alias clipboard_clear="echo lol | pbcopy"
|
||||
alias vlc="/Applications/VLC.app/Contents/MacOS/VLC"
|
||||
@@ -77,7 +77,7 @@ alias tmv="tmux split-window"
|
||||
alias tmh="tmux split-window -h"
|
||||
alias tms="tmux select-pane -t"
|
||||
alias tmk="killall tmux; tmux"
|
||||
PROMPT="%{$fg[red]%}%n%{$reset_color%} at %{$fg[green]%}%m%{$fg[green]%}%{$reset_color%}"$'\n'"=> "
|
||||
PROMPT="%{$fg_bold[red]%}%n%{$fg_no_bold[white]%} at %{$fg_bold[green]%}%m%{$fg_no_bold[white]%}"$'\n'"=> "
|
||||
|
||||
expand-or-complete-with-dots(){
|
||||
echo -n "e[31m.....\e[0m"
|
||||
@@ -133,22 +133,22 @@ function rprompt-git-current-branch {
|
||||
color=%B%F{blue}
|
||||
fi
|
||||
|
||||
echo "on $color$name$action%f%b "
|
||||
echo "on %{$fg_bold[white]%}$color$name$action%f%b %{$reset_color%}"
|
||||
}
|
||||
|
||||
function cabal_sandbox_info() {
|
||||
cabal_files=(*.cabal(N))
|
||||
if [ $#cabal_files -gt 0 ]; then
|
||||
if [ -f cabal.sandbox.config ]; then
|
||||
echo " is %{$fg[green]%}sandboxed%{$reset_color%}"
|
||||
echo "%{$fg_no_bold[white]%} is %{$fg_bold[green]%}sandboxed%{$reset_color%}"
|
||||
else
|
||||
echo " is %{$fg[red]%}not sandboxed%{$reset_color%}"
|
||||
echo "%{$fg_no_bold[white]%} is %{$fg_bold[red]%}not sandboxed%{$reset_color%}"
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
RPROMPT='`rprompt-git-current-branch`'
|
||||
RPROMPT+="in %{$fg[yellow]%}%~%{$reset_color%}"
|
||||
RPROMPT+="%{$fg[white]%}in %{$fg_bold[yellow]%}%~%{$reset_color%}"
|
||||
RPROMPT+='`cabal_sandbox_info`'
|
||||
|
||||
function ghc-pkg-reset() {
|
||||
|
Reference in New Issue
Block a user