Wednesday, November 16, 2016

How to load updated syntax files using native packages?

I've been experimenting with native packages (~/.vim/pack/me/start/{repo1,repo2}, and I've noticed that they don't seem to support plugins that include syntax files that are meant to override the ones included with vim. An example would be most of vim-polyglot.

If I add a package containing an updated syntax file for, say, Python, then vim will not see the updated syntax file and will always use the one that it shipped with.

What I think is happening is this. Vim starts with the directories containing its shipped syntax files in the runtime path. When it loads each package, it appends that package to the runtime path. When you load a Python file, it searches the runtime path from start to end for a Python syntax file, finds its stock syntax file first, and uses that.

How should I set up vim-polyglot if I'm using native packages?

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

No comments: