diff options
author | johannst <stoelp@eit.uni-kl.de> | 2016-10-19 16:21:52 +0200 |
---|---|---|
committer | johannst <stoelp@eit.uni-kl.de> | 2016-10-19 16:21:52 +0200 |
commit | 630c85719fb52e3edb9c98a04a716d956223c9d0 (patch) | |
tree | 2099b9e2bcce1e5f29daffb0848c86c7844059dd | |
parent | 449186bb8bb51e462ec35b9d420afc14383016df (diff) | |
download | dotfiles-630c85719fb52e3edb9c98a04a716d956223c9d0.tar.gz dotfiles-630c85719fb52e3edb9c98a04a716d956223c9d0.zip |
added vi movement in bash; vim changed keymaps to be non-recursive and changed layout of quickfix window, added auto save/restore (but currently disabled)
-rw-r--r-- | .vimrc | 35 | ||||
-rw-r--r-- | bashrc | 2 | ||||
-rw-r--r-- | inputrc | 5 |
3 files changed, 28 insertions, 14 deletions
@@ -61,6 +61,9 @@ set nocompatible " make vim less vi "}}} +"autocmd VimEnter * silent! source .vim_last_session +"autocmd QuitPre * mksession! .vim_last_session + function! TriggerSCons(arg_string) let base_cmd = "scons -u " let &makeprg=base_cmd.a:arg_string @@ -100,6 +103,7 @@ set backspace=2 " had some issues with BS on empty line didn't del set noautowrite " never write a file unless I request it. set noautowriteall " NEVER. set noautoread " don't automatically re-read changed files. +set nowrap " Line/Column settings set number " Display line numbers @@ -152,36 +156,39 @@ set noerrorbells set novisualbell " automatically open Quickfix -autocmd QuickFixCmdPost [^l]* nested cwindow -autocmd QuickFixCmdPost l* nested lwindow +autocmd QuickFixCmdPost [^l]* nested botright cwindow +autocmd QuickFixCmdPost l* nested botright lwindow "{{{ Keymaps + " unset . +" noremap . <nop> " set leader key "execute "set <M-s>=\es" let mapleader=";" " re-source .vimrc - map <leader>v :source ~/.vimrc<CR> + nnoremap <leader>v :source ~/.vimrc<CR> "remap esc button - imap jj <Esc> +" inoremap <Esc> <nop> + inoremap jj <Esc> " quit buffer noremap <leader>q :bd " re-adjust indentation - map <leader>f mzgg=G`z + nnoremap <leader>f mzgg=G`z " navigate between different splits - map <C-Down> <C-w>j - map <C-Up> <C-w>k - map <C-Right> <C-w>l - map <C-Left> <C-w>h - map <C-j> <C-w>j - map <C-k> <C-w>k - map <C-l> <C-w>l - map <C-h> <C-w>h + nnoremap <C-Down> <C-w>j + nnoremap <C-Up> <C-w>k + nnoremap <C-Right> <C-w>l + nnoremap <C-Left> <C-w>h + nnoremap <C-j> <C-w>j + nnoremap <C-k> <C-w>k + nnoremap <C-l> <C-w>l + nnoremap <C-h> <C-w>h " resize splits "map <C-j> <C-w>5- @@ -210,7 +217,7 @@ autocmd QuickFixCmdPost l* nested lwindow " add a marker fold snippet (for C/C++) nnoremap <C-f> o//{{{ <Esc>o//}}}<Esc><Up>A - imap <C-f> <ESC><C-f> + inoremap <C-f> <ESC>o//{{{ <Esc>o//}}}<Esc><Up>A " only works with v-block (not v-line) vnoremap <C-f> VV'<O//{{{<Esc>'>o//}}}<Esc>'<<ESC><Up>A @@ -6,6 +6,8 @@ if [ "$TERM" == "screen" ]; then export TERM=screen-256color; fi if [ "$TERM" == "xterm" ]; then export TERM=xterm-256color; fi +# enable vi mode (use 'bind -P' to see bindings) +set -o vi # disable sticky mode stty -ixon @@ -0,0 +1,5 @@ +# dotfiles -- inputrc +# author: johannst + +set keymap vi-insert +"jj": vi-movement-mode |