@mstar-harness/engine 3.7.3 → 3.8.1

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.
Files changed (2) hide show
  1. package/dist/engine.js +5 -1
  2. package/package.json +1 -1
package/dist/engine.js CHANGED
@@ -2819,12 +2819,16 @@ function reviewPackage(base, head, outFile, opts = {}) {
2819
2819
  mkdirSync6(mkdirAfterGate, { recursive: true });
2820
2820
  }
2821
2821
  const run = (args) => execFileSync3("git", args, { cwd, maxBuffer: GIT_CAPTURE_MAX_BYTES });
2822
+ const commits = run(["log", "--oneline", `${base}..${head}`]);
2823
+ if (commits.length === 0) {
2824
+ throw new SddScriptError(`review package range ${base}..${head} is empty in ${cwd} — refusing to write an empty package ` + `(run the command from the branch worktree, not the control checkout)`, 1);
2825
+ }
2822
2826
  const parts = [
2823
2827
  Buffer.from(`# Review package: ${base}..${head}
2824
2828
 
2825
2829
  ## Commits
2826
2830
  `),
2827
- run(["log", "--oneline", `${base}..${head}`]),
2831
+ commits,
2828
2832
  Buffer.from(`
2829
2833
  ## Files changed
2830
2834
  `),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mstar-harness/engine",
3
- "version": "3.7.3",
3
+ "version": "3.8.1",
4
4
  "description": "Morning Star Harness Workflow Engine — deterministic workflow enforcement library (path, status, lease, dispatch, sdd, iteration, lint gates).",
5
5
  "license": "MIT",
6
6
  "repository": {