Coder Social home page Coder Social logo

Use consistent versioning about wizznic HOT 3 CLOSED

AMDmi3 avatar AMDmi3 commented on July 1, 2024
Use consistent versioning

from wizznic.

Comments (3)

DusteDdk avatar DusteDdk commented on July 1, 2024 1

Hi, thank you very much for the comprehensive feedback, I'm going to go with semantic then, starting at version 400, that will make things easier. :) I think I'll update the things later and make a new release, version 400.1.0. I'll also update the documentation to reflect that this is used.

from wizznic.

DusteDdk avatar DusteDdk commented on July 1, 2024

Thanks for your input, and yes, you are right, it's quite a mess indeed!
Build-numbers don't quite cut it, since downstream builds would be different numbers.
GIT sha's are nice, but one can't easily tell which is the newest.
Could use semantic, but I'm almost never breaking compatibility with previous data formats, so it'd be something like version 1.1.9001 :)

I thought of using "number of commits" as a version number, since I do not rewrite history or squash.
But that's still less than Build 380 (or 400 for that matter).

I was thinking of using git log | wc -l (number of lines in commit history) as a version number, it will be larger than any other number, and never decrease.

What do you think of that hack ?

Oh, I could also use ISO date as a version number?
2020-04-06

from wizznic.

AMDmi3 avatar AMDmi3 commented on July 1, 2024

GIT sha's are nice, but one can't easily tell which is the newest

Precisely, these should never be used as or in version numbers.

Could use semantic, but I'm almost never breaking compatibility with previous data formats, so it'd be something like version 1.1.9001 :)

That's OK and you should not worry about it. Btw, you increase minor (not pach) on new features, so it's more likely to be something like 1.23.1. And note that you've used the word almost, that's exactly what major version is for, even if it stays 1 most of the time.

I thought of using "number of commits" as a version number, since I do not rewrite history or squash.
But that's still less than Build 380 (or 400 for that matter).

You could just start semver at 400.0.1 or 400.1.0.

I was thinking of using git log | wc -l (number of lines in commit history) as a version number, it will be larger than any other number, and never decrease.

I'd avoid this because git log format may not be guaranteed to be stable, non-contiguous versions are confusing, and that's a strange thing to tie versions to in general. You may also need to branch from older point in commit history at some point, e.g. to release a hotfix for a latest release, while having more commits on master you're not ready to release yet.

Oh, I could also use ISO date as a version number?

I'd avoid this as some repositories package git snapshots and use dates as versions and there's no way to tell such snapshot from official release version in this case. Also dates have unfortunate psychological side effect of users treating dates with non-current year as outdated or abandoned projects.

Summarizing, I'd suggest semver as most bulletproof, standard and common, with usual rules (bump major for breaking changes, or just reserve it for some force major cases, bump minor for new features, bump patch for other smaller changes such as bugfixes), optionally starting at 400 or so to make it higher than any currently used versions.

from wizznic.

Related Issues (10)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.