@eventmodelers/cli 1.0.50 → 1.0.51
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cli.js +28 -0
- package/package.json +1 -1
package/cli.js
CHANGED
|
@@ -1852,6 +1852,34 @@ program
|
|
|
1852
1852
|
console.log(` ✓ Unset core.hooksPath (was "${currentHooksPath}") — the commit-scope guard is now off. Run \`init-hooks\` again to turn it back on.`);
|
|
1853
1853
|
});
|
|
1854
1854
|
|
|
1855
|
+
program
|
|
1856
|
+
.command('run-checks')
|
|
1857
|
+
.alias('run:checks')
|
|
1858
|
+
.description("Run this project's commit-scope checks (.build-kit/lib/check-commit-scope.cjs, the same runner .githooks/pre-commit calls) against the currently staged changeset. Works for any build-kit stack — stacks/installs that ship no checks yet report that and exit 0, so this is safe to call unconditionally (e.g. from an agent loop) without checking the stack first.")
|
|
1859
|
+
.action(() => {
|
|
1860
|
+
const cwd = process.cwd();
|
|
1861
|
+
// Mirrors `run`'s buildKitDir resolution: modeling-kit/bridge-kit installs share
|
|
1862
|
+
// KIT_DIR_NAMES but never ship check-commit-scope.cjs, so prefer whichever
|
|
1863
|
+
// installed dir isn't one of those over blindly taking the first match.
|
|
1864
|
+
const installedKitDirs = findAllInstalledKitDirs(cwd);
|
|
1865
|
+
const modelingKitDir = installedKitDirs.find((d) => d.endsWith(MODELING_KIT.kitDirName)) ?? null;
|
|
1866
|
+
const bridgeKitDir = installedKitDirs.find((d) => d.endsWith(BRIDGE_KIT.kitDirName)) ?? null;
|
|
1867
|
+
const kitDir = installedKitDirs.find((d) => d !== modelingKitDir && d !== bridgeKitDir) ?? installedKitDirs[0];
|
|
1868
|
+
|
|
1869
|
+
const checkScript = join(kitDir, 'lib', 'check-commit-scope.cjs');
|
|
1870
|
+
if (!existsSync(checkScript)) {
|
|
1871
|
+
console.log(`ℹ️ ${relative(cwd, kitDir)} ships no checks yet — nothing to run.`);
|
|
1872
|
+
return;
|
|
1873
|
+
}
|
|
1874
|
+
|
|
1875
|
+
console.log(`🔎 Running checks from ${relative(cwd, checkScript)}...`);
|
|
1876
|
+
try {
|
|
1877
|
+
execSync(`node "${checkScript}"`, { cwd: kitDir, stdio: 'inherit' });
|
|
1878
|
+
} catch (err) {
|
|
1879
|
+
process.exit(err.status || 1);
|
|
1880
|
+
}
|
|
1881
|
+
});
|
|
1882
|
+
|
|
1855
1883
|
credentialFlags(program
|
|
1856
1884
|
.command('init-config')
|
|
1857
1885
|
.description('Configure credentials only — writes .eventmodelers/config.json in the current directory, or ~/.eventmodelers/config.json with --global')
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@eventmodelers/cli",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.51",
|
|
4
4
|
"description": "Eventmodelers CLI — real-time Claude agent + skills for Claude Code, for any stack (Node, Supabase, Axon, Cratis, OpenCQRS, UmaDB, Kurrent, or modeling-only)",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|