From 17319d9ac1b948c2aaf20fa1c66269245d8e320b Mon Sep 17 00:00:00 2001 From: Alvie Rahman Date: Sun, 22 Aug 2021 20:37:09 +0100 Subject: [PATCH] Add basic vimrc --- basic.vimrc | 39 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 basic.vimrc diff --git a/basic.vimrc b/basic.vimrc new file mode 100644 index 0000000..7497a33 --- /dev/null +++ b/basic.vimrc @@ -0,0 +1,39 @@ +" my basic minimal vimrc for easy installation: +" curl https://notes.alv.cx/basic.vimrc > ~/.vimrc + +set number +set relativenumber +set lazyredraw +set undofile +set undodir=~/.undodir +set ignorecase + +nnoremap +nnoremap +nnoremap +nnoremap + +noremap H ^ +noremap L $ +noremap ^ H +noremap $ L + +hi Normal ctermbg=None +highlight VertSplit cterm=None ctermfg=8 ctermbg=None +highlight StatusLine cterm=underline ctermfg=8 ctermbg=None +highlight StatusLineNC cterm=underline ctermfg=8 ctermbg=None + +highlight LineNr ctermfg=8 ctermbg=None +highlight LineNrAbove ctermfg=8 ctermbg=None +highlight LineNrBelow ctermfg=8 ctermbg=None +highlight CursorLineNr ctermfg=8 ctermbg=None +highlight FoldColumn ctermfg=8 ctermbg=None +highlight SignColumn ctermfg=8 ctermbg=None + +au VimEnter,WinEnter,BufWinEnter * setlocal cursorline +au VimEnter,WinEnter,BufWinEnter * setlocal cursorcolumn +au WinLeave,BufLeave,BufWinLeave * setlocal nocursorline +au WinLeave,BufLeave,BufWinLeave * setlocal nocursorcolumn + +autocmd FileType yaml setlocal ts=2 sts=2 sw=2 expandtab +autocmd FileType yml setlocal ts=2 sts=2 sw=2 expandtab