dotfiles/.config/nvim/init.vim

42 lines
1 KiB
VimL

" defines plugin directory
" Install plugins from vim with :PlugInstall
call plug#begin('~/.local/share/nvim/plugged')
Plug 'tpope/vim-sensible'
Plug 'stephpy/vim-yaml'
call plug#end()
" many of these come from
" http://stevelosh.com/blog/2010/09/coming-home-to-vim/#using-the-leader
" sets tabs to be 4 characters, expanded into spaces, but still removable with
" one press of backspace.
" great explanation: http://vimcasts.org/transcripts/2/en/
set tabstop=4
set shiftwidth=4
set softtabstop=4
set expandtab
" shows linenumbers relative to the one you are on, for easy movement and
" dNUMBERd deletions
set relativenumber
" keeps an undofile next to files so that you can even undo if vim is closed
" in between
set undofile
let mapleader = "<space>"
" ignores case by default but will use case when search is specifically not
" all lowercased
set ignorecase
set smartcase
" remove search highlights by pressing space+n
nnoremap <leader>n :noh<cr>
" move around between matching brackets with tab
nnoremap <tab> %
nnoremap <tab> %