Files
dbtool-cli-v1/scripts/release/version.mjs
Paperclip CTO 7424491944
Some checks failed
release-smoke / macos-13 / x86_64-apple-darwin (push) Has been cancelled
release-smoke / ubuntu-latest / x86_64-unknown-linux-gnu (push) Has been cancelled
release-smoke / windows-latest / x86_64-pc-windows-msvc (push) Has been cancelled
chore: bootstrap independent git workflow
Co-Authored-By: Paperclip <noreply@paperclip.ing>
2026-03-26 03:49:29 +00:00

12 lines
364 B
JavaScript

import { readFileSync } from "node:fs";
const cargoToml = readFileSync(new URL("../../Cargo.toml", import.meta.url), "utf8");
const match = cargoToml.match(/\[workspace\.package\][\s\S]*?version\s*=\s*"([^"]+)"/);
if (!match) {
console.error("failed to resolve workspace.package.version from Cargo.toml");
process.exit(1);
}
process.stdout.write(match[1]);