2015-07-18 17:05:45 -04:00
|
|
|
if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'scala') == -1
|
|
|
|
|
2015-02-11 14:27:11 -05:00
|
|
|
"
|
|
|
|
" Support for Tagbar -- https://github.com/majutsushi/tagbar
|
|
|
|
"
|
|
|
|
" Hat tip to Leonard Ehrenfried for the built-in ctags deffile:
|
|
|
|
" https://leonard.io/blog/2013/04/editing-scala-with-vim/
|
|
|
|
"
|
|
|
|
if !exists(':Tagbar')
|
|
|
|
finish
|
|
|
|
endif
|
|
|
|
|
|
|
|
let g:tagbar_type_scala = {
|
|
|
|
\ 'ctagstype' : 'scala',
|
2015-03-11 00:56:33 -04:00
|
|
|
\ 'sro' : '.',
|
2015-02-11 14:27:11 -05:00
|
|
|
\ 'kinds' : [
|
2015-03-11 00:56:33 -04:00
|
|
|
\ 'p:packages',
|
|
|
|
\ 'T:types:1',
|
2015-02-11 14:27:11 -05:00
|
|
|
\ 't:traits',
|
|
|
|
\ 'o:objects',
|
2015-03-11 00:56:33 -04:00
|
|
|
\ 'O:case objects',
|
2015-02-11 14:27:11 -05:00
|
|
|
\ 'c:classes',
|
2015-03-11 00:56:33 -04:00
|
|
|
\ 'C:case classes',
|
|
|
|
\ 'm:methods',
|
|
|
|
\ 'V:values:1',
|
|
|
|
\ 'v:variables:1'
|
|
|
|
\ ]
|
2015-02-11 14:27:11 -05:00
|
|
|
\ }
|
|
|
|
|
|
|
|
" In case you've updated/customized your ~/.ctags and prefer to use it.
|
|
|
|
if get(g:, 'scala_use_builtin_tagbar_defs', 1)
|
|
|
|
let g:tagbar_type_scala.deffile = expand('<sfile>:p:h:h:h') . '/ctags/scala.ctags'
|
|
|
|
endif
|
2015-07-18 17:05:45 -04:00
|
|
|
|
|
|
|
endif
|