From ffa37d86e443cf347f99b9a999c85e7d58ce9a05 Mon Sep 17 00:00:00 2001 From: Tobias Reisinger Date: Tue, 7 Jan 2020 12:02:43 +0100 Subject: [PATCH] add: vim plugin change: zsh PS1 --- .config/vim/vimrc | 9 ++++++++- .config/zsh/.zshrc | 7 ++++--- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/.config/vim/vimrc b/.config/vim/vimrc index 00603f7..c4c3ebf 100644 --- a/.config/vim/vimrc +++ b/.config/vim/vimrc @@ -19,12 +19,19 @@ set encoding=utf-8 set nowrap -" Save cursor position. I don't understand this part :) +" Save cursor position. I don't understand this part if has("autocmd") au BufReadPost * if line("'\"") > 0 && line("'\"") <= line("$") | exe "normal! g`\"" | endif endif +" Plug plugins using VimPlug call plug#begin('~/.config/vim/plugged') Plug 'editorconfig/editorconfig-vim' Plug 'airblade/vim-gitgutter' + Plug 'fidian/hexmode' + Plug 'scrooloose/nerdtree' call plug#end() + +" Nerd Tree Configuration +map :NERDTreeToggle +autocmd bufenter * if (winnr("$") == 1 && exists("b:NERDTree") && b:NERDTree.isTabTree()) | q | endif diff --git a/.config/zsh/.zshrc b/.config/zsh/.zshrc index a9011b1..5e38d01 100644 --- a/.config/zsh/.zshrc +++ b/.config/zsh/.zshrc @@ -1,6 +1,9 @@ +[ -f $HOME/.profile ] && source $HOME/.profile + # Enable colors and change prompt: autoload -U colors && colors -PS1="%B%{$fg[red]%}[%{$fg[yellow]%}%n%{$fg[green]%}@%{$fg[blue]%}%M %{$fg[magenta]%}%~%{$fg[red]%}]%{$reset_color%}$%b " +PS1="%B%{$fg[red]%}[%{$fg[yellow]%}%n%{$fg[green]%}@%{$fg[blue]%}%M %{$fg[magenta]%}%~%{$fg[red]%}]%{$reset_color%} +$%b " # History in cache directory: HISTSIZE=10000 @@ -37,7 +40,5 @@ echo -ne '\e[1 q' # Use beam shape cursor on startup. autoload edit-command-line; zle -N edit-command-line bindkey '^e' edit-command-line -[ -f $HOME/.profile ] && source $HOME/.profile - # Load zsh-syntax-highlighting; should be last. source /usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh 2>/dev/null