Last active
April 19, 2018 23:33
-
-
Save kmtr/438cb48fad3be9bf8121ad2a7dc8553f to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[[plugins]] | |
repo = 'Shougo/dein.vim' | |
[[plugins]] # Japanese doc | |
repo = 'vim-jp/vimdoc-ja' | |
hook_add = ''' | |
set helplang=ja,en | |
''' | |
[[plugins]] | |
repo = 'Shougo/vimproc.vim' | |
hook_post_update = ''' | |
if dein#util#_is_windows() | |
let cmd = 'tools\\update-dll-mingw' | |
elseif dein#util#_is_cygwin() | |
let cmd = 'make -f make_cygwin.mak' | |
elseif executable('gmake') | |
let cmd = 'gmake' | |
else | |
let cmd = 'make' | |
endif | |
let g:dein#plugin.build = cmd | |
''' | |
[[plugins]] | |
repo = 'Shougo/deoplete.nvim' | |
hook_add = 'let g:deoplete#enable_at_startup = 1' | |
[[plugins]] | |
repo = 'thinca/vim-quickrun' | |
hook_add = ''' | |
let g:quickrun_config = { | |
\ '_': { | |
\ 'outputter/error/error' : 'quickfix', | |
\ 'outputter/buffer/split' : ':botright', | |
\ 'outputter/buffer/close_on_empty' : 1, | |
\ 'outputter/error/success' : 'buffer', | |
\ 'outputter' : 'error' | |
\ } | |
\} | |
''' | |
[[plugins]] | |
repo = 'easymotion/vim-easymotion' | |
hook_add = ''' | |
let g:EasyMotion_leader_key = '<Space><Space>' | |
''' | |
[[plugins]] # hybrid | |
repo = 'w0ng/vim-hybrid' | |
hook_add = ''' | |
autocmd ColorScheme hybrid highlight LineNr ctermfg=DarkGrey | |
set background=dark | |
let g:hybrid_use_iTerm_colors = 1 | |
colorscheme hybrid | |
''' | |
[[plugins]] | |
repo = 'vim-airline/vim-airline' | |
[[plugins]] | |
repo = 'vim-airline/vim-airline-themes' | |
[[plugins]] | |
repo = 'scrooloose/nerdtree' | |
hook_add = ''' | |
map <C-n> :NERDTreeToggle<CR> | |
''' | |
[[plugins]] | |
repo = 'Xuyuanp/nerdtree-git-plugin' | |
[[plugins]] # Golang | |
repo = 'fatih/vim-go' | |
on_ft = 'go' | |
# F18 means S-F6 | |
hook_add = ''' | |
let g:go_fmt_command = "goimports" | |
autocmd Filetype go noremap <buffer> <F6> :GoTestFunc<CR> | |
autocmd Filetype go noremap <buffer> <F18> :GoTest<CR> | |
autocmd Filetype go command! -bang AS call go#alternate#Switch(<bang>0, 'split') | |
autocmd Filetype go nnoremap <leader>a :AS<CR> | |
autocmd Filetype go nnoremap <leader>d :GoDecls<CR> | |
autocmd BufWinEnter,BufNewFile *_test.go setlocal filetype=go.test | |
''' | |
[[plugins]] | |
repo = 'zchee/deoplete-go' | |
build = 'make' | |
on_ft = 'go' | |
depends = ['deoplete.nvim'] | |
hook_source = ''' | |
let g:deoplete#sources#go#gocode_binary = $GOPATH . '/bin/gocode' | |
''' | |
[[plugins]] | |
repo = 'rust-lang/rust.vim' | |
hook_add = ''' | |
let g:rustfmt_autosave = 1 | |
''' | |
[[plugins]] | |
repo = 'racer-rust/vim-racer' | |
hook_add = ''' | |
let g:racer_cmd = expand('~/.cargo/bin/racer') | |
''' | |
[[plugins]] | |
repo = 'prabirshrestha/async.vim' | |
[[plugins]] | |
repo = 'prabirshrestha/vim-lsp' | |
hook_add = ''' | |
if executable('rls') | |
au User lsp_setup call lsp#register_server({ | |
\ 'name': 'rls', | |
\ 'cmd': {server_info->['rustup', 'run', 'nightly', 'rls']}, | |
\ 'whitelist': ['rust'], | |
\ }) | |
endif | |
''' | |
[[plugins]] # Toml | |
repo = 'cespare/vim-toml' | |
[[plugins]] | |
repo = 'junegunn/fzf' | |
build = './install' | |
merged = 0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
" reset augroup | |
augroup MyAutoCmd | |
autocmd! | |
augroup END | |
let $CACHE = empty($XDG_CACHE_HOME) ? expand('$HOME/.cache') : $XDG_CACHE_HOME | |
let $CONFIG = empty($XDG_CONFIG_HOME) ? expand('$HOME/.config') : $XDG_CONFIG_HOME | |
let $DATA = empty($XDG_DATA_HOME) ? expand('$HOME/.local/share') : $XDG_DATA_HOME | |
let g:python_host_prog = '/usr/local/bin/python3' | |
" {{{ dein | |
let s:dein_dir = expand('$DATA/dein') | |
if &runtimepath !~# '/dein.vim' | |
let s:dein_repo_dir = s:dein_dir . '/repos/github.com/Shougo/dein.vim' | |
" Auto Download | |
if !isdirectory(s:dein_repo_dir) | |
call system('git clone https://github.com/Shougo/dein.vim ' . shellescape(s:dein_repo_dir)) | |
endif | |
execute 'set runtimepath^=' . s:dein_repo_dir | |
endif | |
" dein.vim settings | |
if dein#load_state(s:dein_dir) | |
call dein#begin(s:dein_dir) | |
let s:toml_dir = expand('$CONFIG/dein') | |
call dein#load_toml(s:toml_dir . '/plugins.toml', {'lazy': 0}) | |
call dein#load_toml(s:toml_dir . '/lazy.toml', {'lazy': 1}) | |
if has('python3') | |
call dein#load_toml(s:toml_dir . '/python.toml', {'lazy': 1}) | |
endif | |
call dein#end() | |
call dein#save_state() | |
endif | |
if has('vim_starting') && dein#check_install() | |
call dein#install() | |
endif | |
" }}} | |
filetype plugin indent on | |
syntax enable | |
set number | |
set title | |
set ambiwidth=double | |
set tabstop=4 | |
set expandtab | |
set shiftwidth=4 | |
set smartindent | |
set nrformats-=octal | |
set virtualedit=block | |
set whichwrap=b,s,[,],<,> | |
set backspace=indent,eol,start | |
set ignorecase | |
set smartcase | |
set cursorline | |
map! <C-a> <Home> | |
map! <C-e> <End> | |
nmap <silent> <Esc><Esc> :nohlsearch<CR><esc> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment