mirror of
https://github.com/junegunn/vim-plug.git
synced 2026-01-01 21:33:21 +08:00
Prototype implementation of dependency resolution (#2)
This commit is contained in:
29
README.md
29
README.md
@@ -14,6 +14,7 @@ Somewhere between [Pathogen](https://github.com/tpope/vim-pathogen) and
|
||||
- Parallel installation/update (requires
|
||||
[+ruby](http://junegunn.kr/2013/09/installing-vim-with-ruby-support/))
|
||||
- Smallest possible feature set
|
||||
- Dependency resolution using `Plugfile` (experimental)
|
||||
|
||||
### Cons.
|
||||
|
||||
@@ -64,6 +65,34 @@ plugins with `plug#begin(path)` call.
|
||||
|
||||
(Default number of threads = `g:plug_threads` or 16)
|
||||
|
||||
### Dependency resolution
|
||||
|
||||
If a Vim plugin specifies its dependent plugins in `Plugfile` in its root
|
||||
directory, vim-plug will automatically source it recursively during the
|
||||
installation.
|
||||
|
||||
A `Plugfile` should contain a set of `Plug` commands for the dependent plugins.
|
||||
|
||||
I've created two dummy repositories with Plugfiles as an example to this scheme.
|
||||
|
||||
- [junegunn/dummy1](https://github.com/junegunn/dummy1)
|
||||
- `Plug 'junegunn/vim-scroll-position'`
|
||||
- `Plug 'junegunn/dummy2'`
|
||||
- [junegunn/dummy2](https://github.com/junegunn/dummy2)
|
||||
- `Plug 'junegunn/Zenburn'`
|
||||
- `Plug 'junegunn/jellybeans.vim'`
|
||||
- `Plug 'junegunn/dummy1'`
|
||||
- (Circular dependencies are ignored)
|
||||
|
||||
If you put `Plug 'junegunn/dummy1'` in your configuration file, and run
|
||||
`:PlugInstall`,
|
||||
|
||||
1. vim-plug first installs dummy1
|
||||
2. And sees if the repository has Plugfile
|
||||
3. Plugfile is loaded and vim-plug discovers dependent plugins
|
||||
4. Dependent plugins are then installed as well, and their Plugfiles are
|
||||
examined and their dependencies are resolved recursively.
|
||||
|
||||
### Articles
|
||||
|
||||
- [Writing my own Vim plugin manager](http://junegunn.kr/2013/09/writing-my-own-vim-plugin-manager)
|
||||
|
||||
Reference in New Issue
Block a user