Version numbers
-
Eric S
- Milestone set to OpenBaskerville 0.1
-
Simon Pascal Klein
Great idea. I’m swamped with work and won’t have the time atm to look into SemVer closely but I think I‘m sold.
How does this impact adding new commits — do we need to
git describethem?—Pascal.
-
Eric S
No, we’ll only have to tag minor versions. Then the build script can derive a patch version number, and bake that into the font.
Markdown ate my line breaks (I’ve updated the ticket):
git describe yields output, the last tag, and the number of commits since that tag.
We could programmatically base our version number on that.This is just making it easy on ourselves, it is not really true to the semver spec because there they do expect you to tag every version manually…
-
Eric S
From the upcoming rakefile :)
# derive a version number from the current tag + number of commits (patch # version) task :_version_number => :_has_git do git_describe = `git describe`.strip # v0.0.0-49-gb5cc6c0 -> 0.0.49 (gb5cc6c0) # http://www.rubular.com/r/kqgRzxS8G9 version_number = git_describe.gsub /[v]?([0-9]+)\.([0-9]+)\.0-([0-9]+)-([\w]+)/ , '\1.\2.\3 (\4)' if version_number == git_describe abort "Unable to automatically generate patch version number" end version_number_short = version_number.split[0] puts "Generated version number #{version_number}" endMy idea is that in the source tree the font has a general version number like 0.0.x development series, based on the current minor version number. So we only have to change this every time we release a minor version (which is not all too often).
To make a patch release, we just run ''rake release'' it derives the actual version number from the git tree, bakes this into the font metadata, and generates an OTF named OpenBaskerville-0.0.49.otf or similar?
-
Simon Pascal Klein
I think I understand, and yea, sounds good. Will have to grab you sometime by Skype and get you to run me through it so I can update the OB web page to add the info to the workflow.
-
Eric S
- State changed from new to resolved
Okay, then I’ll close the ticket for now, we’ll have to see how it works out in practice :)
Reference commit: https://github.com/klepas/open-baskerville/commit/939f078870987826d...
Please Sign in or create a free account to add a new ticket.
With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.