Chronologic Versioning, because we're in the future.
- This module has some sharp corners and is not ready for primetime yet. You have been warned.
import * as chronver from "https://deno.land/x/chronver/mod.ts";
chronver.valid("1.2.3"); // false
chronver.valid("v0000.00.00"); // false
chronver.valid("0000.00.00"); // true
chronver.valid("1970.01.01"); // true
chronver.valid("1970.01.01-alpha.10.beta+build.unicorn.rainbow"); // true
new chronver.ChronVer("0000.00.00", { initialize: true }).version; // "2022.09.26" (the current date in ChronVer format)
# WIP
deno run --allow-read cli.ts
A "version" is described by the 2019.05.19
specification found at https://chronver.org.
You will need to first download this repo, cd
into it, and install Deno before proceeding further.
# lint all TypeScript files
deno lint
# type-check file
deno check cli.ts
deno check mod.ts
deno check test.ts
# run the tests in `test.ts`
deno test