Semantic Versioning (SemVer)

DEVELOPMENT

Quick Definition

Semantic Versioning (SemVer) is a versioning scheme of the form MAJOR.MINOR.PATCH (e.g. 2.7.3) where each component has specific meaning: MAJOR increments on breaking changes, MINOR on backward-compatible new features, PATCH on backward-compatible bug fixes. The convention lets dependency managers reason about upgrade safety: "any 2.x version" is safe; "any 3.x" might break you.

How it works

Package managers (npm, Cargo, pip via pep440) parse version strings as SemVer. Range specifiers like ^2.7.3 mean "compatible with 2.7.3, allow 2.x.x but not 3.x". ~2.7.3 is more restrictive: "2.7.x but not 2.8". >=2.7.3 is unbounded.

Pre-release identifiers (1.0.0-rc.1) and build metadata (1.0.0+sha.abc) extend the format. Pre-1.0 versions are by convention unstable; the spec treats 0.x.x as having no compatibility guarantees, though in practice most teams treat 0.MAJOR.PATCH as their working contract.

Why it matters

Without SemVer, every dependency upgrade is a coin flip. With SemVer (and discipline in following it), automated dependency updates become tractable and most upgrades are safe. Renovate, Dependabot, and similar tools rely on SemVer to suggest safe updates.

Where you'll see this on TerminalFeed

The Git cheat sheet includes patterns for tagging releases that align with SemVer.