@rtrentjones/greenlight 0.2.17 → 0.2.19

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/bin.js +14 -5
  2. package/package.json +1 -1
package/dist/bin.js CHANGED
@@ -426,7 +426,7 @@ function tokensForTool(tool) {
426
426
  }
427
427
 
428
428
  // src/version.ts
429
- var MODULE_REF = "v0.2.17";
429
+ var MODULE_REF = "v0.2.19";
430
430
  var MODULE_SOURCE_BASE = "git::https://github.com/RTrentJones/greenlight.git//infra/modules";
431
431
  function moduleSource(module, ref = MODULE_REF) {
432
432
  return `${MODULE_SOURCE_BASE}/${module}?ref=${ref}`;
@@ -1956,12 +1956,17 @@ function dirCheck(label, dir) {
1956
1956
  }
1957
1957
  function conformanceChecks(t, root) {
1958
1958
  const out = [];
1959
- const specRel = t.external ? `verify/${t.name}.config.ts` : join4(t.dir ?? join4("tools", t.name), "verify.config.ts");
1960
- const hasSpec = existsSync7(join4(root, specRel));
1959
+ const toolDir = t.dir ?? join4("tools", t.name);
1960
+ const specCandidates = t.external ? [
1961
+ `verify/${t.name}.config.ts`,
1962
+ join4(toolDir, `verify/${t.name}.config.ts`),
1963
+ join4(toolDir, "verify.config.ts")
1964
+ ] : [join4(toolDir, "verify.config.ts")];
1965
+ const found = specCandidates.find((p) => existsSync7(join4(root, p)));
1961
1966
  out.push({
1962
1967
  name: `${t.name}: in the verify loop`,
1963
- status: hasSpec ? "ok" : "warn",
1964
- detail: hasSpec ? specRel : `no ${specRel} \u2014 verify falls back to the lane default`
1968
+ status: found ? "ok" : "warn",
1969
+ detail: found ?? `no verify spec (looked: ${specCandidates.join(", ")}) \u2014 falls back to the lane default`
1965
1970
  });
1966
1971
  const builtIn = !t.external && t.target === "workers";
1967
1972
  const platformPreview = t.target === "vercel";
@@ -2522,6 +2527,10 @@ async function previewCommand(args) {
2522
2527
  let pass;
2523
2528
  if (entry.preview) {
2524
2529
  pass = await previewViaDescriptor(entry, name, port);
2530
+ } else if (entry.external && entry.target === "vercel") {
2531
+ throw new Error(
2532
+ `"${name}" is a vercel tool \u2014 its pre-prod gate is Vercel's per-PR preview deployment (the greenlight-verify.yml on deployment_status), not \`greenlight preview\`. Open a PR on its repo to get a preview + verify.`
2533
+ );
2525
2534
  } else if (entry.external) {
2526
2535
  throw new Error(
2527
2536
  `"${name}" is external and has no preview descriptor \u2014 add preview:{ command, \u2026 } to its manifest entry (e.g. a docker command), or preview it from its own repo`
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rtrentjones/greenlight",
3
- "version": "0.2.17",
3
+ "version": "0.2.19",
4
4
  "description": "Greenlight CLI — setup and lifecycle for the harness.",
5
5
  "license": "MIT",
6
6
  "repository": {