google/glaive — pull request #7 by chiphogg (2013-12-30 17:29:01+00:00)
Title: Let Glaive use the canonical name to configure autoinstalled plugins

This makes its behaviour consistent with pre-installed plugins. It lets us configure a plugin at `my-plugin/` using
```vim
Glaive my_plugin flag
```
instead of
```vim
Glaive my-plugin flag
```

It is somewhat less efficient, since one has to call `maktaba#plugin#CanonicalName` on O(N) elements (N is the size of `maktaba#rtp#LeafDirs()`) every time Glaive configures a plugin. So, O(NG) calls of `CanonicalName()` with G Glaive plugins. We _might_ want to consider making the keys of `maktaba#rtp#LeafDirs()` be the canonical names, rather than the path names; this seems somewhat natural, and would take us back to O(N). Then again, we might not. (Not to mention, I think that would technically force us to version 2.x, since it's backwards-incompatible. Yikes!)

At any rate, I think this is more correct and it probably justifies a small performance hit. (Although I admit I haven't attempted to measure such a hit.)

---

Oh, and I also documented the rules for the plugin name in the `:Glaive` command.