diff --git a/.gitconfig b/.gitconfig index 1ec5ce1..723d9bd 100644 --- a/.gitconfig +++ b/.gitconfig @@ -2,4 +2,4 @@ name = Michael Grote email = michael.grote@posteo.de [credential] - helper = store + helper = store diff --git a/.vimrc b/.vimrc index 72479a3..23c9a26 100644 --- a/.vimrc +++ b/.vimrc @@ -7,6 +7,9 @@ set rtp+=~/.vim/bundle/Vundle.vim call vundle#begin('~/.vim/plugged') " Let Vundle manage Vundle Plugin 'VundleVim/Vundle.vim' +Plugin 'vim-airline/vim-airline' +Plugin 'vim-airline/vim-airline-themes' +Plugin 'matze/vim-move' Plugin 'sheerun/vim-polyglot' Plugin 'ctrlpvim/ctrlp.vim' Plugin 'lifepillar/vim-solarized8' @@ -14,6 +17,7 @@ Plugin 'Yggdroot/indentLine' Plugin 'tpope/vim-fugitive' Plugin 'jiangmiao/auto-pairs' Plugin 'preservim/nerdtree' +Plugin 'unkiwii/vim-nerdtree-sync' " Install: " vim +PluginInstall +qall " oder @@ -25,17 +29,29 @@ let g:AutoPairsShortcutToggle = '' " Toogle Auto-Pairs mit Strg+P " zur Autovervollständigung von Klammern " -" NERDtree +" NERDtree + nerdtree-sync +"https://github.com/preservim/nerdtree let NERDTreeShowHidden = 1 " Show hidden files let NERDTreeShowLineNumbers = 0 " Hide line numbers let NERDTreeMinimalMenu = 1 " Use the minimal menu (m) let NERDTreeWinSize = 31 " Set panel width to 31 columns nmap :NERDTreeToggle " ruft NERDtree mit F2 auf -autocmd StdinReadPre * let s:std_in=1 " Start NERDTree. If a file is specified, move the cursor to its window. -autocmd VimEnter * NERDTree | if argc() > 0 || exists("s:std_in") | wincmd p | endif " Start NERDTree. If a file is specified, move the cursor to its window. +" Start NERDTree. If a file is specified, move the cursor to its window. +autocmd StdinReadPre * let s:std_in=1 +autocmd VimEnter * NERDTree | if argc() > 0 || exists("s:std_in") | wincmd p | endif +let g:nerdtree_sync_cursorline = 1 " highlight the file in tree +" open the existing NERDTree on each new tab. +autocmd BufWinEnter * silent NERDTreeMirror " +" exit Vim if NERDTree is the only window left. +autocmd BufEnter * if tabpagenr('$') == 1 && winnr('$') == 1 && exists('b:NERDTree') && b:NERDTree.isTabTree() | + \ quit | endif +" +" vim-move + + " Tastenkürzel -nmap :tabnew +nmap :tabnew:NERDTreeFind " erstellt neuen tab und öffnet den open-dialog " " indentLine @@ -89,4 +105,3 @@ let g:ctrlp_map = '' "aufruf mit strg+f set wildignore+=*/tmp/*,*.so,*.swp,*.zip " MacOSX/Linux set wildignore+=*\\tmp\\*,*.swp,*.zip,*.exe " Windows let g:ctrlp_custom_ignore = '\v[\/]\.(git|hg|svn)$' -