-
-
Notifications
You must be signed in to change notification settings - Fork 14.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
vim: add plugins #4499
vim: add plugins #4499
Conversation
Why do you add Git commit ids don't work well as a version numbers. Can you replace it with "commit date" or "commit date + git commit id" as version? |
@bjornfor, I have a function which maps over all vim plugins, and so I added the attribute "path" as it is available for the other plugins, but not for YouCompleteMe. |
@jagajaga, git ids are more or less random hashes that don't increment monotonously for new version, which breaks |
Not only do git hashes not increment like normal version numbers, they may also begin with a non-digit character, causing nix-env to not see it as a version number at all (instead it becomes a part of the package name, in the eyes of nix-env). When you try to install such a package it will cause a conflict with the older package. Really bad usability :-) |
@jagajaga: Ah, I didn't see the comment about tool. Thanks for the explanation. Btw, I've been wanting to get rid of the "path" argument, or at least make it optional, because all plugins just install to a path made up of their name anyway. So currently "path" just duplicates plugin name. |
@jagajaga: If you want a bigger database of vim plugins, maybe https://github.com/MarcWeber/vim-addon-manager would be of interest? |
@jagajaga: Try "nix-prefetch-git" from the "nix-prefetch-scripts" package. |
5775a0e
to
4d5208a
Compare
@bjornfor done. |
4d5208a
to
d31305e
Compare
@jagajaga: It seems some of the new plugins still use git hash as version. I assume there are no release / git tags for these plugins? Since we don't package multiple variants (e.g. stable and bleeding edge), I don't think having "-git" in package name is needed. (And if it did, "git" should be part of the package attrname too.) Speaking of package attrnames, they should have dashes instead of camelCase, to match package name. (Yes, there are offenders already in nixpkgs, but we're trying to clean up.) Note that simpleDerivation does not add any prefix to plugin names. So that, for example, the "rust-..." thing being added here will be named "rust-..." in nix-env too. Until we add something like |
d31305e
to
3826955
Compare
@bjornfor it's ok now? |
@jagajaga: Oh, you changed existing stuff too? I didn't expect you to do that, but ok :-) Can you do the cleanup in a separate commit, preserving old attributes for backward compatibility, like (I don't feel strongly about the backward compatibility of vim plugin attributes, but it cost little to add them.) I still see some upper/lower case mix in package attr + name. Please use lower-case everywhere. |
@bjornfor didn't get what you mean. |
@jagajaga: I mean that doing clean-up to existing plugins and adding new plugins are two logically separate changes; it would be natural to have one "cleanup" commit and one "add plugins" commit. Combining those two changes in a single commit named "add plugins" is wrong/bad, IMHO. |
@bjornfor that's going to be very hard (I have to redo everything). Indeed it's really nearly the same things (they are updated, no?). I can rename commit if it's ok. |
@bjornfor that's nice! |
7242009
to
f3a24af
Compare
Btw, it's strange behavior of travis CI, because on my local machine it's all has built succesfully. |
f3a24af
to
e31dedf
Compare
Using date instead of rev See #4499 (comment) for more info why.
Add some plugins by the tool I've created.
https://gist.github.com/3c7ba009ee6756e12978 (updated vim2nix)