@savvy-web/silk-core 0.4.11 → 0.4.12

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/index.d.ts CHANGED
@@ -936,9 +936,13 @@ export declare const SavvyOkfSection: SectionId;
936
936
  * `node_modules/.bin` is common to all four supported package managers, so
937
937
  * one probe covers them.
938
938
  *
939
- * The positional argument is `"$ROOT"`, the PROJECT root `okfit` starts config
940
- * discovery from — not the bundle directory. Passing `"$ROOT/okf"` makes the
941
- * tool look for the bundle at `okf/okf` and exit 3.
939
+ * The sync runs in a subshell that `cd`s to `"$ROOT"`, the PROJECT root `okfit`
940
+ * starts config discovery from — not the bundle directory (`"$ROOT/okf"` makes
941
+ * the tool look for the bundle at `okf/okf` and exit 3). The root is never
942
+ * passed as an argument: `@okfit/cli` before 0.13.0 accepts only a trailing
943
+ * positional, 0.13.0 and later accept only `--root` and refuse the positional,
944
+ * but every version defaults the root to the current directory, so the `cd`
945
+ * works across the whole range without a version probe.
942
946
  *
943
947
  * Once it runs, a non-zero exit FAILS the commit (`|| exit 1`): a bundle the
944
948
  * tool cannot sync is a broken bundle, and letting the commit through would
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@savvy-web/silk-core",
3
- "version": "0.4.11",
3
+ "version": "0.4.12",
4
4
  "private": false,
5
5
  "description": "Platform-free domain core of the Silk Suite: schemas, tagged errors, and the PR-body contract",
6
6
  "homepage": "https://github.com/savvy-web/systems/tree/main/packages/silk-core",
@@ -43,9 +43,13 @@ const SavvyOkfSection = SectionId.make({
43
43
  * `node_modules/.bin` is common to all four supported package managers, so
44
44
  * one probe covers them.
45
45
  *
46
- * The positional argument is `"$ROOT"`, the PROJECT root `okfit` starts config
47
- * discovery from — not the bundle directory. Passing `"$ROOT/okf"` makes the
48
- * tool look for the bundle at `okf/okf` and exit 3.
46
+ * The sync runs in a subshell that `cd`s to `"$ROOT"`, the PROJECT root `okfit`
47
+ * starts config discovery from — not the bundle directory (`"$ROOT/okf"` makes
48
+ * the tool look for the bundle at `okf/okf` and exit 3). The root is never
49
+ * passed as an argument: `@okfit/cli` before 0.13.0 accepts only a trailing
50
+ * positional, 0.13.0 and later accept only `--root` and refuse the positional,
51
+ * but every version defaults the root to the current directory, so the `cd`
52
+ * works across the whole range without a version probe.
49
53
  *
50
54
  * Once it runs, a non-zero exit FAILS the commit (`|| exit 1`): a bundle the
51
55
  * tool cannot sync is a broken bundle, and letting the commit through would
@@ -73,9 +77,9 @@ function savvyOkfSync() {
73
77
  # Index mode reads concepts from disk, so skip it while okf/ carries untracked or
74
78
  # unstaged work: a commit must never link a concept it does not contain.
75
79
  if git -C "$ROOT" status --porcelain --untracked-files=all -- okf | grep -q '^.[^ ]'; then
76
- pm_exec okfit sync --staged --only generated "$ROOT" || exit 1
80
+ (cd "$ROOT" && pm_exec okfit sync --staged --only generated) || exit 1
77
81
  else
78
- pm_exec okfit sync --staged "$ROOT" || exit 1
82
+ (cd "$ROOT" && pm_exec okfit sync --staged) || exit 1
79
83
  fi
80
84
  fi`;
81
85
  }