rollup / awesome

⚡️ Delightful Rollup Plugins, Packages, and Resources
MIT License
2.55k stars 139 forks source link

Add rollup-plugin-git-version #53

Closed IvanSanchez closed 4 years ago

IvanSanchez commented 4 years ago

Awesome Contribution Checklist:

Please Provide a Link A Repository for Your Addition

https://gitlab.com/IvanSanchez/rollup-plugin-git-version

Please Describe Your Addition

Injects git branch and revision hash into import { version } from "package.json". e.g. if your package.json contains version: "1.2.3", this plugin turns the imported value into "1.2.3+master.890abc".

If I recall correctly, rollup-plugin-git-version was present in the previous incarnations of the rollup plugins list.

shellscape commented 4 years ago

Thanks for proposing a new plugin. My apologies if this was on a list originally and lost, the basis of the list was the plugins list in the Rollup wiki, which has been deprecated. There are a few things that prevent us from accepting this at the moment:

Overall I think if the plugin had a little spring cleaning and added tests, we'd be in good shape to add it.

IvanSanchez commented 4 years ago

Sounds good, I'll see if I can spare a bit of time to clean it up a bit.

IvanSanchez commented 4 years ago

OK, I've rewrote the plugin removing the git-rev dependency completely. I'll see about some tests tomorrow, hopefully.

shellscape commented 4 years ago

Thanks for submitting this initially. Checking back in, it doesn't look like any tests have been added. We're going to close for now, but ping if you get the chance to add tests.