diff options
author | listout <listout@protonmail.com> | 2021-04-13 21:47:37 +0530 |
---|---|---|
committer | listout <listout@protonmail.com> | 2021-04-13 21:47:37 +0530 |
commit | 502989c3cd4bf1e6cf2663a5a633645940b3f7b7 (patch) | |
tree | f776227268371a60bf9316f297835eea10a13b60 /configs/basic.vim |
vim config
Diffstat (limited to 'configs/basic.vim')
-rw-r--r-- | configs/basic.vim | 97 |
1 files changed, 97 insertions, 0 deletions
diff --git a/configs/basic.vim b/configs/basic.vim new file mode 100644 index 0000000..279eae3 --- /dev/null +++ b/configs/basic.vim @@ -0,0 +1,97 @@ +" Line numbering +" set relativenumber number +set number + +" Enable mouse scroll +set mouse=a + +" Lines vim should remember +set history=500 + +" Don't be Vi compatible +set nocompatible + +" Enable filytype plugin and indent +filetype plugin indent on + +" Remap leader key +let mapleader="," + +" Autoread file if changed externally +set autoread +au FocusGained,BufEnter * checktime + +" Wildmenu in COMMAND mode +set path+=** +set wildmenu +set showcmd +" Ignore compiled files +set wildignore=*.o,*~,~*.pyc +set wildignore+=*.bmp,*.gif,*.ico,*.jpg,*.png,*.ico +set wildignore+=node_modules/*,browse_components/* +if has("win16") || has("win32") + set wildignore+=.git\*,.hg\*,.svn\* +else + set wildignore+=*/.git/*,*/.hg/*,*/.svn/*,*/.DS_Store +endif + +" Make backspace work as it should +set backspace=eol,start,indent +set whichwrap+=<,>,h,l + +" Better searching +set ignorecase smartcase nohlsearch + +" No redraw when using macros +set lazyredraw + +" Vim's regular expression magic +set magic + +" Show matching braces +set showmatch + +" How many tenths of seconds ro blink +set mat=2 + +" Syntax highlighting +syntax enable + +" utf-8 encoding +set encoding=utf-8 +if &encoding != 'utf-8' + set encoding=utf-8 +endif + +" unix as standard file format +set ffs=unix,dos,mac + +" Hidden buffers +set hidden + +" No backup files +set nobackup nowritebackup + +" No swap files +set noswapfile + +" Correct indentation +set autoindent smartindent + +" Tab settings +set noexpandtab smarttab tabstop=4 shiftwidth=4 + +" Share system clipboard +set clipboard=unnamedplus + +" Netrw directory history +let g:netrw_dirhistmax=0 + +" Autoremove unwanted whitespaces +autocmd BufWritePre * %s/\s\+$//e + +" Shell +set shell=zsh + +" Python host +let g:python3_host_prog='/usr/bin/python' |