Stamp the version as YYYY.MM.DD-<branch>-<sha>
build.rs builds the string (git, or SLINUXM_* env for builds without .git) and the lib exposes it as VERSION. --version, /healthz, /api/v1/ping, MCP server info and OTel service.version use it; OpenAPI info.version stays on the semver so docs/openapi.json does not change per commit. The flake passes the commit date and short rev to the package.
This commit is contained in:
1 parent
435a54a02d
commit
1a30b20ac0
18 files changed
+322
-18
No files matched your search
@@ -236,6 +236,13 @@ fn binary_end_to_end() {
|
||||
smoke.port = 1; // placeholder; start_server picks a real port
|
||||
smoke.write_config();
|
||||
|
||||
let version = smoke.cli(&["--version"]);
|
||||
let stamped = version.trim().strip_prefix("slinuxm ").unwrap_or_default();
|
||||
assert!(
|
||||
skyg_linux_tracker::version::is_valid(stamped),
|
||||
"--version printed {version:?}, want `slinuxm YYYY.MM.DD-<branch>-<sha>`"
|
||||
);
|
||||
|
||||
let out = smoke.cli(&["token", "create", "smoke"]);
|
||||
let token = out.trim().to_owned();
|
||||
assert!(
|
||||
|
||||
Reference in new issue
Block a user