From 7385ca20855741915e932a4c8764d83938c8f2bb Mon Sep 17 00:00:00 2001 From: Ivan Malison Date: Tue, 8 Apr 2014 04:08:57 -0700 Subject: [PATCH] Fix zshrc and prompt. --- bootstrap.sh | 1 + dotfiles/lib/zsh.sh | 3 +-- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/bootstrap.sh b/bootstrap.sh index d6e9d273..7e267f35 100755 --- a/bootstrap.sh +++ b/bootstrap.sh @@ -17,6 +17,7 @@ function symlink_dotfiles() { for filename in *; do local link_destination="$HOME/.$filename" local absolute_path="$($readlink_command -f $filename)" + [[ -a $link_destination ]] && mv $link_destination ~/.dotfiles-backups ln -si $absolute_path $link_destination done } diff --git a/dotfiles/lib/zsh.sh b/dotfiles/lib/zsh.sh index b670b777..659ec34d 100644 --- a/dotfiles/lib/zsh.sh +++ b/dotfiles/lib/zsh.sh @@ -11,7 +11,6 @@ autoload -U edit-command-line zle -N edit-command-line bindkey '\C-x\C-e' edit-command-line -local function current_directory() { local PWD=$(pwd) @@ -27,4 +26,4 @@ function git_prompt_info () { fi } -PROMPT="%{$FG[040]%}%n%{$reset_color%} %{$FG[239]%}at%{$reset_color%} %{$FG[033]%}$(hostname -s)%{$reset_color%} %{$FG[239]%}in%{$reset_color%} %{$terminfo[bold]$FG[226]%}\$(current_directory)%{$reset_color%}\$(git_prompt_info) %{$FG[239]%}with \$(colored_sandbox_string)%{$FG[255]%} " +PROMPT="%{$FG[040]%}%n%{$reset_color%} %{$FG[239]%}at%{$reset_color%} %{$FG[033]%}$(hostname -s)%{$reset_color%} %{$FG[239]%}in%{$reset_color%} %{$terminfo[bold]$FG[226]%}$(current_directory)%{$reset_color%}$(git_prompt_info) %{$FG[239]%}with $(colored_sandbox_string)%{$FG[255]%} "