corral
corral copied to clipboard
"revision" and "version" terms are mixed in codebase and presented poorly in the UI/docs
See below:
~/tmp/foo ➜ corral add github.com/seantallen/lori.git --revision 0.0.1
~/tmp/foo ➜ cat corral.json
{
"packages": [],
"deps": [
{
"locator": "github.com/seantallen/lori.git",
"version": ""
}
],
"info": {
"description": "",
"homepage": "",
"license": "",
"documentation_url": "",
"version": "",
"name": ""
}
}
I'm not sure given that "version" can take a a revision that we need both version and revision. And we have no rules in place for how one overrides the other if both are present (or rather we have no stated rules). I wonder if version override revision and because we are doing an empty version now, revision doesn't appear.
Huh so ok, what is going on here is that --revision sets what goes into the lock.json and --version sets what goes into the corral.json.
So version can be a semantic constraint and revision would lock it to a specific version.
The interface to do this is a bit confusing to me. It seems like it could easily get out of shape as corral will let me set a revision that is outside a version constraint. Which should end up being "not doable".
corral add github.com/seantallen/lori.git --version 0.0.1 --revision 0.0.2
as an example.