Use tags to version templates
jescalan opened this issue · comments
So here's my proposal, which I'm about to start working on a PR for. Just wanted to see if anyone else had thoughts or opinions on this. At the moment, each template is always kept up to date with the latest commit made to the repo that it was added from. This means that there's no versioning, and if you push a commit that changes things, it becomes an issue.
My proposal is to use github tags to make an attempt at basic versioning for templates. So the process would be as such. If no version is specified, check the tags and snap to the latest tag. If there are no tags, use the latest commit. If there was a version specified, like sprout add https://github.com/foo/bar@v0.1.2
, look for that tag and pull that version of the repo. If that tag doesn't exist throw an error.
It's not quite as robust as npm, but at the same time I don't think it needs to be. Just the basics.
tags sounds logical. 👍 from me
👍 sounds good to me