Semantic versioning library with optional hotfix component (fork of github.com/blang/semver)
Find a file
Maxim Slipenko 790c9aea07 feat(parse-tolerant): preserve OmitPatch for 2-component input
ParseTolerant now keeps two-component versions short instead of padding
them to three components. "v1.2" and "v11.0-alpha.0" round-trip with
OmitPatch=true. Single-component input ("1") is still padded to two
components ("1.0") so Parse can accept it.
2026-05-06 18:42:05 +03:00
examples chore: rename project 2025-09-17 11:22:52 +03:00
.travis.yml Add test for go 1.12 2019-04-14 20:25:27 +02:00
go.mod chore: rename project 2025-09-17 11:22:52 +03:00
json.go Implements json.Marshaler and json.Unmarshaler 2015-01-13 00:49:13 -08:00
json_test.go feat: support 2-component versions (Major.Minor) with optional prerelease 2026-05-06 18:01:07 +03:00
LICENSE Add license 2014-07-01 22:09:37 +02:00
package.json gx publish 3.6.1 2019-04-14 18:04:19 +02:00
range.go Simplify string.Index in range 2019-04-14 12:29:17 +02:00
range_test.go feat: support 2-component versions (Major.Minor) with optional prerelease 2026-05-06 18:01:07 +03:00
README.md chore: rename project 2025-09-17 11:22:52 +03:00
semver.go feat(parse-tolerant): preserve OmitPatch for 2-component input 2026-05-06 18:42:05 +03:00
semver_test.go feat(parse-tolerant): preserve OmitPatch for 2-component input 2026-05-06 18:42:05 +03:00
sort.go Documentation, code cleaning 2015-06-20 10:58:49 +02:00
sort_test.go New() and Make() 2015-04-05 15:04:57 +02:00
sql.go Fix golint issue 2019-04-14 11:59:07 +02:00
sql_test.go feat: support 2-component versions (Major.Minor) with optional prerelease 2026-05-06 18:01:07 +03:00

This is a fork of github.com/blang/semver, extending the semantic versioning library to support an optional Hotfix component in version strings (e.g., 1.2.3.4). The project aims to be a drop-in replacement for the original github.com/blang/semver/v4 library as much as possible, maintaining compatibility with existing code while adding support for four-part version numbers.