[vim] Port minimal Vundle setup from old vimrc
This commit is contained in:
parent
9a6e082862
commit
275bfc1a94
1 changed files with 62 additions and 0 deletions
62
vimrc
62
vimrc
|
@ -1,4 +1,66 @@
|
||||||
set nocompatible
|
set nocompatible
|
||||||
|
if &shell =~# 'fish$'
|
||||||
|
set shell=sh
|
||||||
|
endif
|
||||||
|
"[Use Plug-ins and Plug-in Manager(Vundle) only on UNIX or MAC OS]"
|
||||||
|
if has("unix") || has("mac")
|
||||||
|
filetype off
|
||||||
|
"[Download and install Vundle Plug-in Manager]"
|
||||||
|
if !isdirectory(expand("$HOME/.vim/bundle"))
|
||||||
|
silent !mkdir -p $HOME/.vim/bundle
|
||||||
|
silent cd $HOME/.vim/bundle
|
||||||
|
silent !git clone https://github.com/gmarik/Vundle.vim.git
|
||||||
|
silent cd $HOME
|
||||||
|
endif
|
||||||
|
"[Run Plug-ins]"
|
||||||
|
set runtimepath+=$HOME/.vim/bundle/Vundle.vim
|
||||||
|
call vundle#begin()
|
||||||
|
Plugin 'gmarik/Vundle.vim'
|
||||||
|
map <F3> :VundleUpdate<CR>
|
||||||
|
Plugin 'dag/vim-fish'
|
||||||
|
Plugin 'w0rp/ale'
|
||||||
|
let g:ale_linters = {
|
||||||
|
\ 'cpp': ['g++'],
|
||||||
|
\ 'c': ['clang']
|
||||||
|
\ }
|
||||||
|
let g:ale_c_gcc_options='-std=c99 -pedantic'
|
||||||
|
let g:ale_sign_error = '●'
|
||||||
|
let g:ale_sign_warning = '●'
|
||||||
|
Plugin 'itchyny/lightline.vim'
|
||||||
|
let g:lightline = {
|
||||||
|
\ 'active': {
|
||||||
|
\ 'left': [['mode', 'paste'], ['filename', 'modified']],
|
||||||
|
\ 'right': [['lineinfo'],
|
||||||
|
\ ['percent'],
|
||||||
|
\ ['readonly', 'linter_warnings', 'linter_errors', 'linter_ok'],
|
||||||
|
\ ['fileformat'],
|
||||||
|
\ ['fileencoding']
|
||||||
|
\ ]
|
||||||
|
\ },
|
||||||
|
\ 'component_expand': {
|
||||||
|
\ 'linter_warnings': 'LightlineLinterWarnings',
|
||||||
|
\ 'linter_errors': 'LightlineLinterErrors',
|
||||||
|
\ 'linter_ok': 'LightlineLinterOK',
|
||||||
|
\ 'lineinfo': 'LineInfo'
|
||||||
|
\ },
|
||||||
|
\ 'component_type': {
|
||||||
|
\ 'readonly': 'error',
|
||||||
|
\ 'linter_warnings': 'warning',
|
||||||
|
\ 'linter_errors': 'error'
|
||||||
|
\ },
|
||||||
|
\}
|
||||||
|
if executable('ctags')
|
||||||
|
Plugin 'ludovicchabant/vim-gutentags'
|
||||||
|
endif
|
||||||
|
Plugin 'beyondmarc/opengl.vim'
|
||||||
|
Plugin 'tikhomirov/vim-glsl'
|
||||||
|
Plugin 'jamessan/vim-gnupg'
|
||||||
|
"[Autodetect indent style of a file]"
|
||||||
|
Plugin 'tcbbd/detectindent'
|
||||||
|
let g:detectindent_preferred_indent=4
|
||||||
|
let g:detectindent_autodetect=1
|
||||||
|
call vundle#end()
|
||||||
|
endif
|
||||||
" Allow backspacing over everything in insert mode.
|
" Allow backspacing over everything in insert mode.
|
||||||
set backspace=indent,eol,start
|
set backspace=indent,eol,start
|
||||||
set number
|
set number
|
||||||
|
|
Loading…
Reference in a new issue