Skip to content

ci: add semantic versioning

Emil Laurentowicz requested to merge elaurentowicz/cibuglog:versioning into master

Add semantic versioning [1] for better documentation and to be able to quickly revert to previous, working versions of CIBugLog in case of some fatal bugs slipping through.

After this change, when pushing a commit to the master branch, the Pipeline build stage will be launched, just like before, and the container with "pre-release" (was "latest") tag will be built and pushed to the registry. However, if the commit is pushed with a tag that matches the regular expression that is put in the code (basically v[number].[number].[number], e.g. "v5.12.10") the container with "latest" and version tags will be built and pushed to the registry.

Adding "v" before version was added due to GitLab's limitations in creating protected tags - there are no regular expressions allowed, only either an individual name or a wildcard '*'. Considering protecting these tags would be a good idea, adding this "v" allows creating "v*" protection rule.

[1] https://semver.org/

WIP: I want to take a closer look into .gitlab-ci.yml file and make some changes if needed, e.g. migrate only to rules because only is deprecated: https://docs.gitlab.com/ee/ci/yaml/#only--except

EDIT: Scratch that. I will add it in a separate MR.

Edited by Emil Laurentowicz

Merge request reports

Loading