The Need, the Goal...
By "project-based config" I mean a project contained in a git repo that contains all the vim configuration -- vimrc and plugins and colorschemes -- right there in the repo. In my case this is in the repo's
cd path/to/project && vi -u .config/vimrc some-script.py should... somehow ...load all the plugins/colorschemes contained in that
.config directory, ignoring the standard
~/.vim/* config files.
- Plugin manager:
- a plugin made for this
- like https://github.com/LucHermitte/local_vimrc as a possibility
- manual configuration
- perhaps has multiple ways it could be achieved?
- vim considers
~/.vim/to always be siblings so if you do
vi -u path/to/config/vimrcsince vim is smart it will automatically look for plugins inside
- vim considers
- something else?
- #4 doesn't seem to exist.
- #2 doesn't match my criteria, as "an automatic way of sourcing vimrc from current directory" is a different use-case, I don't want automatic, it should require explicit intention by invoking
-uor something comparable.
- #1: I've used pathogen for years, but I'm not sure if it's even capable of this. I tried using vim-plug and could get that working in the same way pathogen works (with standard location of config files) but couldn't get it working for this use case.
- #3 I've spent hours reading
:h runtimepath, and trying to derive a solution from them but nothing yet works. The trouble here is that
:h packagesis not clear about the distinction between
foobarin the context of a plugin that we find off Github (it describes unzipping individually zipped files). Not a single plugin has I've seen has a
optdirectory, but it says to manually create that, though it's not explicitly clear about "where"... so just guess, and try every option! I did this to no avail. Additionally,
:h packpathis not helpful and
:h packageshas no mention of it... but these two things might need to be used in tandem(?).