Some notes to myself about why I prefer to version source-controlled software using Git tags instead of commits:

  • Version commits pollute the commit history with messages irrelevant to changes in functionality
  • Version commits can create merge conflicts if a PR is based on an incremented version and another version goes to the integration branch while the PR is out
  • CI commits can fail the build if two PRs are merged close together: when the first build tries to push the commit with the updated version, it will fail because it does not have the second commit.
  • CI commits require developers to pull commits every time they push to CI, even if they are the only ones who have committed.
  • Version commits can makes it difficult to match up other tags that were added to the commit on which the version commit is .

Problems with versioning with Git tags:

  • Github doesn’t (yet) provide protection of tags, so someone might delete them from the remote repository. There are some community calls for the feature in the Github Community Forum and the unofficial Github issues repo.
    • A workaround is being notified when a tag changes, at least, so that you can audit and restore.
  • For Python, there is better tooling around version commits (bumpversion) than around managing versions in tags.