semantic versioning
A version numbering scheme of three numbers, major.minor.patch, raised for breaking changes, new features and fixes respectively.
In more detail
Increase the patch number for backwards-compatible bug fixes, the minor number for backwards-compatible new features and the major number for breaking changes, so 1.4.2 to 2.0.0 warns users that something will break. It is the publisher's promise rather than a guarantee, so updates still deserve review.
Examples
Ansible collections use semantic versioning, so ansible.posix 2.0.0 may break playbooks written for 1.x.The lesson bumps [1, 2, 3] to 1.2.4 (patch), 1.3.0 (minor) and 2.0.0 (major).Changesets picks the highest bump requested by the pending changes for each package.dist/calc-2.4.0.tarv1.3.0 is the canary and v1.2.0 the stable version traffic returns to.Conventional Commits maps onto it: fix gives a patch bump, feat a minor bump and a breaking change a major bump.git tag -a v1.0 -m 'Release version one'1.2.0 → 1.3.0 new input added (compatible)
1.3.0 → 2.0.0 output renamed (breaking)In Terraform: Providers and registry modules follow it, which is what makes the ~> operator safe. A module that renames or removes an input or output must release a new major version. The number is only a promise; the changelog and the plan are what you actually check.In this course: Versioning a contract the same way tells consumers when they must change their code and when an update is safe. Minor versions add features compatibly, and patch versions only fix bugs.Related terms
- pinning — Fixing an exact version or digest of something you depend on so it cannot change without you noticing.
- Ansible collection — A distribution package of Ansible content, such as modules, plugins, roles and documentation, published under a namespace.
- uses — The workflow key that pulls a published action into a step by name, followed by an @ and a version.
- ImagePolicy — A Flux object that chooses which scanned image tag is the latest allowed one, for example by a semver range.
- breaking change — A change that makes existing users of a program or interface stop working until they change something too.
- backward compatibility — The property that a new version of an interface still works for clients written against the old one.
- Changesets — A tool where each pull request adds a small Markdown file describing its change and its version bump, later combined into releases and changelogs.
- artifact — A file produced by a build, such as a compiled program or an image, that is stored and passed on to later steps.
- digest — A SHA-256 hash of an image's manifest that identifies its exact content and can never be moved to other bytes.
- release — Making a version of software, or one of its behaviours, available to users; also the versioned package being made available.
- rollback — Returning a system to a previous known-good version after a bad change.
- canary release — Sending a small share of real traffic to a new version first, and increasing it only while its metrics stay healthy.
- Conventional Commits — A specification for commit subject lines of the form type(optional scope): description, so tools can read what kind of change each commit is.
- git tag — A name fixed permanently to one commit, usually to mark a release such as v1.0, and the command that creates and lists them.
- version constraint — A string such as "~> 3.6" or ">= 1.6.0" that says which versions of Terraform, a provider or a module are acceptable.
- changelog — A file or page listing the notable changes in each release of a project, newest first.
- pessimistic constraint operator — The ~> version operator, which allows only the rightmost number you wrote to increase.
- API contract — The written promise an API makes about its operations, inputs, outputs and errors, which callers rely on while the code behind it changes.
Taught in
- Using Collections — Ansible Configuration Management at Scale
- Ansible Galaxy — Ansible Configuration Management at Scale
- Versioning Packages And Pipeline Artifacts — Microsoft Azure DevOps Engineer Expert (AZ-400) Exam Prep
- Workflows, Jobs, Steps, and Actions — Continuous Integration & Continuous Delivery Pipelines
- Image Update Automation — Continuous Integration & Continuous Delivery Pipelines
- Vendor & Third-Party Risk Management Programs — Cybersecurity Fundamentals, GRC & Cryptography
- Asymmetric Cryptography: RSA, ECC & Diffie-Hellman — Cybersecurity Fundamentals, GRC & Cryptography
- System Governance: Changesets, Semantic Versioning & Deprecation — Design Systems & Component Engineering
- Building And Versioning The Artifact — DevOps & Site Reliability Engineering
- Continuous Delivery: Blue-Green & Canary Pipelines — Production Full-Stack Engineering
- Conventional Commits — Advanced Git Internals & Distributed Workflows
- Providers And The required_providers Block — Infrastructure as Code with Terraform
- Versioning And Pinning Modules — Infrastructure as Code with Terraform
- Contract Testing Between Services — Automated Testing, TDD & Quality Engineering
- One Hour, No Weights Published — HashiCorp Terraform Associate (004) Exam Prep
- Versions, The Lock File And Provider Aliases — HashiCorp Terraform Associate (004) Exam Prep
- Module Versions: Pin, Upgrade, Re-Initialise — HashiCorp Terraform Associate (004) Exam Prep