Skip to content

product-os/cue-semver

Repository files navigation

cue-semver

CUE based implementation of SemVer, version ranges and comparison.

Implementation based upon semantic versioner for npm.

Usage

Test if version string satisfies a range

Use #SemVer to evaluate a version string into semantic version components. Unify it with #SemVerSatisfies and provide a range string. The unification will error if the version does not fall within the range.

foo: {
    version: "1.0.0"
}

foo: this={
    semVer: #SemVer&{#version: this.version} & #SemVerSatisfies&{#range: ">=1.0.0"}
}

Notes

  • node-semver loose option not supported.

TODO

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published