Created
July 10, 2019 04:46
-
-
Save jubnzv/fc362de0776c4f0e2569e196f6c3f0ae to your computer and use it in GitHub Desktop.
This file contains 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
call plug#begin('~/.local/share/nvim/plugged') | |
Plug 'liuchengxu/vista.vim' | |
Plug 'itchyny/lightline.vim' | |
call plug#end() | |
let g:lightline = { | |
\ 'colorscheme': 'gruvbox', | |
\ 'active': { | |
\ 'left': [ [ 'mode', 'paste' ], | |
\ [ 'readonly', 'filename', 'modified' ], | |
\ [ 'method' ] ], | |
\ 'right': [ [ 'lineinfo' ], | |
\ [ 'percent' ], | |
\ [ 'fileformat', 'fileencoding', 'filetype' ] ], | |
\ }, | |
\ 'component_function': { | |
\ 'method': 'NearestMethodOrFunction' | |
\ }, | |
\ } | |
set tags=./tags; | |
let g:vista_default_executive = 'ctags' | |
let g:vista_fzf_preview = ['right:50%'] | |
" Show current method name in lightline | |
function! NearestMethodOrFunction() abort | |
let l:method = get(b:, 'vista_nearest_method_or_function', '') | |
if l:method != '' | |
let l:method = '[' . l:method . ']' | |
endif | |
return l:method | |
endfunction | |
autocmd VimEnter * call vista#RunForNearestMethodOrFunction() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment