Single-source the version from package.json (closes #5)
check / check (push) Successful in 25s

src/index.ts imports package.json for VERSION and bin/quak.ts passes
VERSION to commander, so package.json is the only place the version is
written. tsc copies package.json to dist/package.json, so the import
resolves from the built output; script/build runs the built CLI with
--version to prove it. A test checks VERSION and quak --version against
package.json.

Model: opus-5-5
This commit was merged in pull request #95.
This commit is contained in:
2026-09-23 05:07:47 +02:00
parent 0ca8887f52
commit d05b53d560
5 changed files with 66 additions and 7 deletions
+5 -1
View File
@@ -1,4 +1,8 @@
export const VERSION = "0.0.0";
// package.json is the one place the version is written. tsc copies it to
// dist/package.json, so this path resolves from source and from dist/src/.
import pkg from "../package.json" with { type: "json" };
export const VERSION: string = pkg.version;
export {
Client,