native_messenger icon indicating copy to clipboard operation
native_messenger copied to clipboard

Automatic version numbers

Open bovine3dom opened this issue 4 years ago • 3 comments

https://github.com/achesak/nim-gitapi/blob/master/gitapi.nim

I reckon version = last git tag + (if tag isn't at head: short commit hash)

Probably needs to go in the nimble build script.

At the moment it's easy for the version number and the tag to diverge, and for PRs to fight over version numbers.

bovine3dom avatar Feb 06 '21 09:02 bovine3dom

Hmm, semver-compare as used in nativegate treats version numbers with extra alphanumeric bits as smaller than ones without:

> cmp("0.1.1d", "0.1.1")
-1

So we'll probably need to increment the last digit of the git tag.

bovine3dom avatar Feb 12 '21 17:02 bovine3dom

Considering semver-compare is only 13 lines of code, it shouldn't be too hard to roll our own that does what we want.

Rummskartoffel avatar Feb 12 '21 18:02 Rummskartoffel

I was thinking of the backwards compatibility.

I suppose it doesn't matter if we're adding new things to Tridactyl.

bovine3dom avatar Feb 12 '21 19:02 bovine3dom