ctrlpvim / ctrlp.vim

Active fork of kien/ctrlp.vim—Fuzzy file, buffer, mru, tag, etc finder.
ctrlpvim.github.com/ctrlp.vim
Other
5.57k stars 260 forks source link

Support for mixed filetypes #547

Closed dyllandry closed 4 years ago

dyllandry commented 4 years ago

My filetype is vue.javascript, and I think that is breaking :CtrlPBufTag.

By default when opening a vue file, my filetype is set to vue.javascript. Like this, :CtrlPBufTag does not pickup tags for my vue file. But when I reverse the names and set my filetype to javascript.vue, :CtrlPBufTag works. However, this causes some of my other plugins to break.

Is there a way to configure ctrlp to search for tags relating to multiple filetypes when the filetype is a mixed value like vue.javascript?

Here are more details:

:CtrlPTag shows the tag I am looking for:

featureIsEnabled  vue/src/comp/Home.vue  /^    featureIsEnabled() {$/;"  M

But :CtrlPBufTag from that file shows == NO ENTRIES ==.

My .ctags file is the following:

--options=/home/me/development/ctags-patterns-for-javascript/ctagsrc
--exclude=.git
--exclude=node_modules

Where I've edited the ctagsrc langmap option to include vue files:

--langmap=javascript:.js.es6.es.jsx.mjs.vue
--javascript-kinds=-c-f-m-p-v

--regex-javascript=/^[ \t]*var[ \t]\{1,\}\([A-Za-z0-9_$]\{1,\}\)[ \t]*=[ \t]*\[/\1/A,Array,Arrays/b
--regex-javascript=/^[ \t]*let[ \t]\{1,\}\([A-Za-z0-9_$]\{1,\}\)[ \t]*=[ \t]*\[/\1/A,Array,Arrays/b
--regex-javascript=/^[ \t]*const[ \t]\{1,\}\([A-Za-z0-9_$]\{1,\}\)[ \t]*=[ \t]*\[/\1/A,Array,Arrays/b
...