@bakers-build/addon-herdr 0.7.1-next.7 → 0.8.1-next.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.
@@ -1,3 +1,4 @@
1
+ import type { LaunchWatchOptions } from './launch-script.js';
1
2
  import type { OpenLayout } from './open-layout.js';
2
3
  import type { RootGitExec } from './root-anchor.js';
3
4
  export interface PaneSpec {
@@ -9,17 +10,17 @@ export interface StateConfig {
9
10
  /**
10
11
  * Tab label template. Must contain {identifier} — the conductor matches a
11
12
  * run's tab by its ticket identifier (stop/state), so the identifier is the
12
- * stable anchor in the visible name. Other vars: {title}, {titleSlug},
13
- * {runUuid}, {repoName}, {workspacePath}.
13
+ * stable anchor in the visible name. Other vars: {title}, {title_slug},
14
+ * {run_uuid}, {workspace_path}.
14
15
  */
15
- tabLabel?: string;
16
- workspaceLabel?: string;
16
+ tab_label?: string;
17
+ workspace_label?: string;
17
18
  /**
18
19
  * Root-pane (panel) label template applied via `herdr pane rename` after the
19
20
  * state tab is created (BB-374). Default `{title}`. Distinct from
20
- * {@link tabLabel}: stop/state matching still anchors on the tab label.
21
+ * {@link tab_label}: stop/state matching still anchors on the tab label.
21
22
  */
22
- panelLabel?: string;
23
+ panel_label?: string;
23
24
  /** Extra layout panes (diff/logs); NOT the agent command. */
24
25
  panes?: PaneSpec[];
25
26
  }
@@ -46,18 +47,13 @@ export interface HerdrExecutorOptions {
46
47
  default?: StateConfig;
47
48
  states?: Record<string, StateConfig>;
48
49
  /**
49
- * Launch-watch windows. `startTimeoutMs` is how long startRun waits for the
50
+ * Launch-watch windows. `start_timeout_ms` is how long startRun waits for the
50
51
  * wrapper to write `started` (default 60s, so a slow interactive shell can
51
- * finish rc). `timeoutMs` is the short window after `started` in which an
52
+ * finish rc). `timeout_ms` is the short window after `started` in which an
52
53
  * immediate agent exit fails the launch (default 4000 ms). Tests inject
53
- * shorter windows, including `timeoutMs: 0` to skip the exit wait.
54
+ * shorter windows, including `timeout_ms: 0` to skip the exit wait.
54
55
  */
55
- launchWatch?: {
56
- timeoutMs?: number;
57
- startTimeoutMs?: number;
58
- pollMs?: number;
59
- sleep?: (ms: number) => Promise<void>;
60
- };
56
+ launch_watch?: Omit<LaunchWatchOptions, 'readPane'>;
61
57
  }
62
58
  export interface ResolvedConfig {
63
59
  tabLabel: string;
@@ -1,6 +1,6 @@
1
1
  export const BUILTIN_DEFAULTS = {
2
- tabLabel: '{identifier} · {titleSlug}',
3
- workspaceLabel: '{repoName}',
2
+ tabLabel: '{identifier} · {title_slug}',
3
+ workspaceLabel: '{repo_name}',
4
4
  panelLabel: '{title}',
5
5
  panes: [],
6
6
  };
@@ -8,11 +8,11 @@ export function resolveStateConfig(options, state) {
8
8
  const base = options.default ?? {};
9
9
  const stateCfg = options.states?.[state] ?? {};
10
10
  return {
11
- tabLabel: stateCfg.tabLabel ?? base.tabLabel ?? BUILTIN_DEFAULTS.tabLabel,
12
- workspaceLabel: stateCfg.workspaceLabel ??
13
- base.workspaceLabel ??
11
+ tabLabel: stateCfg.tab_label ?? base.tab_label ?? BUILTIN_DEFAULTS.tabLabel,
12
+ workspaceLabel: stateCfg.workspace_label ??
13
+ base.workspace_label ??
14
14
  BUILTIN_DEFAULTS.workspaceLabel,
15
- panelLabel: stateCfg.panelLabel ?? base.panelLabel ?? BUILTIN_DEFAULTS.panelLabel,
15
+ panelLabel: stateCfg.panel_label ?? base.panel_label ?? BUILTIN_DEFAULTS.panelLabel,
16
16
  panes: stateCfg.panes ?? base.panes ?? BUILTIN_DEFAULTS.panes,
17
17
  };
18
18
  }
@@ -24,6 +24,6 @@ export function renderTemplate(tpl, vars) {
24
24
  }
25
25
  export function assertTabLabelTemplate(tabLabel) {
26
26
  if (!tabLabel.includes('{identifier}')) {
27
- throw new Error(`herdr tabLabel must contain {identifier} for stop/state matching: ${tabLabel}`);
27
+ throw new Error(`herdr tab_label must contain {identifier} for stop/state matching: ${tabLabel}`);
28
28
  }
29
29
  }
package/dist/src/index.js CHANGED
@@ -227,9 +227,9 @@ export class HerdrExecutor {
227
227
  const vars = {
228
228
  identifier: input.ticket.identifier,
229
229
  title: input.ticket.title,
230
- titleSlug: slugify(input.ticket.title),
231
- runUuid: input.run.uuid,
232
- workspacePath: input.workspacePath,
230
+ title_slug: slugify(input.ticket.title),
231
+ run_uuid: input.run.uuid,
232
+ workspace_path: input.workspacePath,
233
233
  };
234
234
  // 3. Create tab — NO --json flag; label includes the run-id token. The tab's
235
235
  // root pane IS the agent pane, so it is created carrying the agent-shell
@@ -249,7 +249,7 @@ export class HerdrExecutor {
249
249
  ]));
250
250
  // BB-374: panel label on the state root pane (best-effort). Tab --label
251
251
  // above stays the stop/state matching string and is intentionally not the
252
- // resolved StateConfig.tabLabel path.
252
+ // resolved StateConfig.tab_label path.
253
253
  await this.execHerdr([
254
254
  'pane',
255
255
  'rename',
@@ -273,7 +273,7 @@ export class HerdrExecutor {
273
273
  launch = writeLaunchScript(this.commandFor(input));
274
274
  await applyPaneLayout(this.execHerdr, rootPaneId, { command: launch.typedCommand, panes: cfg.panes }, input.workspacePath, vars, { env: AGENT_SHELL_ENV });
275
275
  await watchLaunch(launch, {
276
- ...(this.options.launchWatch ?? {}),
276
+ ...(this.options.launch_watch ?? {}),
277
277
  readPane: () => this.execHerdr(['pane', 'read', rootPaneId, '--lines', '40']),
278
278
  });
279
279
  // 6. Return branch as sessionRef (for logging)
@@ -368,7 +368,9 @@ export function herdrExecutor(options = {}) {
368
368
  ...(options.open ? { open: options.open } : {}),
369
369
  ...(options.default ? { default: options.default } : {}),
370
370
  ...(options.states ? { states: options.states } : {}),
371
- ...(options.launchWatch ? { launchWatch: options.launchWatch } : {}),
371
+ ...(options.launch_watch
372
+ ? { launch_watch: options.launch_watch }
373
+ : {}),
372
374
  }, defaultExec, deps.logger);
373
375
  },
374
376
  };
@@ -18,16 +18,16 @@ export interface LaunchScript {
18
18
  export declare function writeLaunchScript(command: string): LaunchScript;
19
19
  export interface LaunchWatchOptions {
20
20
  /** Window after `started` in which an immediate agent exit fails the launch. */
21
- timeoutMs?: number;
21
+ timeout_ms?: number;
22
22
  /** How long to wait for the wrapper to write `started`. Default 60s. */
23
- startTimeoutMs?: number;
24
- pollMs?: number;
23
+ start_timeout_ms?: number;
24
+ poll_ms?: number;
25
25
  sleep?: (ms: number) => Promise<void>;
26
26
  readPane?: () => Promise<string>;
27
27
  }
28
28
  /**
29
- * Poll the launch markers in two phases. Wait up to `startTimeoutMs` for
30
- * `started` (shell start-up), then apply a short `timeoutMs` exit window from
29
+ * Poll the launch markers in two phases. Wait up to `start_timeout_ms` for
30
+ * `started` (shell start-up), then apply a short `timeout_ms` exit window from
31
31
  * that moment. An immediate exit or a script that never starts fails the
32
32
  * launch; an agent still running at the exit deadline is treated as started.
33
33
  */
@@ -52,15 +52,15 @@ const DEFAULT_TIMEOUT_MS = 4000;
52
52
  const DEFAULT_START_TIMEOUT_MS = 60_000;
53
53
  const DEFAULT_POLL_MS = 50;
54
54
  /**
55
- * Poll the launch markers in two phases. Wait up to `startTimeoutMs` for
56
- * `started` (shell start-up), then apply a short `timeoutMs` exit window from
55
+ * Poll the launch markers in two phases. Wait up to `start_timeout_ms` for
56
+ * `started` (shell start-up), then apply a short `timeout_ms` exit window from
57
57
  * that moment. An immediate exit or a script that never starts fails the
58
58
  * launch; an agent still running at the exit deadline is treated as started.
59
59
  */
60
60
  export async function watchLaunch(script, opts = {}) {
61
- const timeoutMs = opts.timeoutMs ?? DEFAULT_TIMEOUT_MS;
62
- const startTimeoutMs = opts.startTimeoutMs ?? DEFAULT_START_TIMEOUT_MS;
63
- const pollMs = opts.pollMs ?? DEFAULT_POLL_MS;
61
+ const timeoutMs = opts.timeout_ms ?? DEFAULT_TIMEOUT_MS;
62
+ const startTimeoutMs = opts.start_timeout_ms ?? DEFAULT_START_TIMEOUT_MS;
63
+ const pollMs = opts.poll_ms ?? DEFAULT_POLL_MS;
64
64
  const sleep = opts.sleep ?? ((ms) => new Promise((r) => setTimeout(r, ms)));
65
65
  const startDeadline = Date.now() + startTimeoutMs;
66
66
  let exitDeadline = 0;
@@ -6,17 +6,17 @@ import { type HerdrExec } from './pane-layout.js';
6
6
  * Layout applied to a fresh worktree's initial (root) pane (BB-139): `command`
7
7
  * launches a tool in the main pane (e.g. `spiceedit`) so the human lands in an
8
8
  * editor instead of a bare shell; `panes[]` are optional splits off it. Same
9
- * shape as the executor's per-state layout minus `tabLabel` — there is only ONE
9
+ * shape as the executor's per-state layout minus `tab_label` — there is only ONE
10
10
  * open layout, not a per-ticket-state map.
11
11
  *
12
- * BB-234: `{identifier}`, `{branch}`, `{title}` and `{worktreePath}` expand in
12
+ * BB-234: `{identifier}`, `{branch}`, `{title}` and `{worktree_path}` expand in
13
13
  * `command` **and** in every `panes[].command`. The root command is rendered
14
14
  * here before the finished layout reaches `applyPaneLayout` — that shared
15
15
  * helper types its root command VERBATIM on purpose, because its other caller
16
16
  * (the run tab) pre-assembles `KEY='value' <agent>` env prefixes whose values
17
17
  * may legitimately contain braces (spec D2).
18
18
  *
19
- * BB-374: `tabLabel` / `panelLabel` are chrome strings applied after the
19
+ * BB-374: `tab_label` / `panel_label` are chrome strings applied after the
20
20
  * layout via `herdr tab rename` / `herdr pane rename` ("panel label" = pane
21
21
  * label). Defaults ship when keys are absent on an active layout; `open: {}`
22
22
  * remains the full opt-out (no command, no splits, no labels). The overview
@@ -34,12 +34,12 @@ export interface OpenLayout {
34
34
  * Overview tab label template. Default: `{identifier} · {title}` (title
35
35
  * truncated to {@link OPEN_TAB_TITLE_MAX} when rendering).
36
36
  */
37
- tabLabel?: string;
37
+ tab_label?: string;
38
38
  /**
39
39
  * Overview root-pane label template (`herdr pane rename`). Default:
40
40
  * `{identifier} · {title}` (full title).
41
41
  */
42
- panelLabel?: string;
42
+ panel_label?: string;
43
43
  }
44
44
  /** Max `{title}` length substituted into the overview **tab** label (BB-374). */
45
45
  export declare const OPEN_TAB_TITLE_MAX = 30;
@@ -27,15 +27,15 @@ export const DEFAULT_OPEN_PANEL_LABEL = '{identifier} · {title}';
27
27
  */
28
28
  export const DEFAULT_OPEN_LAYOUT = {
29
29
  command: 'bakers ui --ticket {identifier}',
30
- tabLabel: DEFAULT_OPEN_TAB_LABEL,
31
- panelLabel: DEFAULT_OPEN_PANEL_LABEL,
30
+ tab_label: DEFAULT_OPEN_TAB_LABEL,
31
+ panel_label: DEFAULT_OPEN_PANEL_LABEL,
32
32
  };
33
33
  /** `open: {}` — the opt-out back to the bare tab: no command, splits or labels. */
34
34
  export function isEmptyLayout(open) {
35
35
  return (open.command === undefined &&
36
36
  !open.panes?.length &&
37
- open.tabLabel === undefined &&
38
- open.panelLabel === undefined);
37
+ open.tab_label === undefined &&
38
+ open.panel_label === undefined);
39
39
  }
40
40
  /**
41
41
  * The root pane of a `worktree create`/`worktree open` response
@@ -95,7 +95,7 @@ export async function applyOpenLayout(execHerdr, logger, open, root, path, ctx)
95
95
  identifier: ctx.identifier,
96
96
  branch: ctx.branch,
97
97
  title: ctx.title,
98
- worktreePath: path,
98
+ worktree_path: path,
99
99
  };
100
100
  const layout = {
101
101
  ...open,
@@ -124,8 +124,8 @@ async function applyOverviewLabels(execHerdr, logger, open, root, vars) {
124
124
  ...vars,
125
125
  title: truncateOpenTabTitle(vars.title ?? ''),
126
126
  };
127
- const tabLabel = renderTemplate(open.tabLabel ?? DEFAULT_OPEN_TAB_LABEL, tabVars);
128
- const panelLabel = renderTemplate(open.panelLabel ?? DEFAULT_OPEN_PANEL_LABEL, vars);
127
+ const tabLabel = renderTemplate(open.tab_label ?? DEFAULT_OPEN_TAB_LABEL, tabVars);
128
+ const panelLabel = renderTemplate(open.panel_label ?? DEFAULT_OPEN_PANEL_LABEL, vars);
129
129
  let tabId = root.tabId;
130
130
  if (!tabId) {
131
131
  try {
@@ -10,7 +10,7 @@ export declare function parsePaneSplit(output: string): string;
10
10
  * split panes. Shared by the executor's per-run tab (`startRun`) and the
11
11
  * workspace's initial open pane (`herdrWorkspace` `open`) — one code path, no
12
12
  * duplication. The per-state `StateConfig` (executor) and the workspace `open`
13
- * option both narrow to this shape (the executor adds `tabLabel`; there is only
13
+ * option both narrow to this shape (the executor adds `tab_label`; there is only
14
14
  * one open layout, not a per-state map).
15
15
  */
16
16
  export interface PaneLayout {
@@ -32,7 +32,7 @@ export interface PaneLayout {
32
32
  * secret, while the command herdr actually runs stays real. An empty layout
33
33
  * (`{}`) issues no calls at all — the caller's unconfigured default is preserved.
34
34
  *
35
- * `opts.env` is forwarded to each split pane as `--env` args (BB_* only, see
35
+ * `opts.env` is forwarded to each split pane as `--env` args (BAKERS_* only, see
36
36
  * {@link envArgs}). It is deliberately per-CALLER rather than baked in: this
37
37
  * primitive serves both the executor's agent tab and the workspace's own open
38
38
  * pane, and only the former's panes are agent-owned (BB-64). The ROOT pane is
@@ -35,7 +35,7 @@ export function parsePaneSplit(output) {
35
35
  * secret, while the command herdr actually runs stays real. An empty layout
36
36
  * (`{}`) issues no calls at all — the caller's unconfigured default is preserved.
37
37
  *
38
- * `opts.env` is forwarded to each split pane as `--env` args (BB_* only, see
38
+ * `opts.env` is forwarded to each split pane as `--env` args (BAKERS_* only, see
39
39
  * {@link envArgs}). It is deliberately per-CALLER rather than baked in: this
40
40
  * primitive serves both the executor's agent tab and the workspace's own open
41
41
  * pane, and only the former's panes are agent-owned (BB-64). The ROOT pane is
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * Marker exported into an AGENT pane's interactive shell, so a user's opt-in
3
3
  * shell init can recognise an agent-run pane at startup and isolate its history
4
- * (BB-64). It is a plain `BB_*` env entry on purpose: it rides {@link envArgs}
4
+ * (BB-64). It is a plain `BAKERS_*` env entry on purpose: it rides {@link envArgs}
5
5
  * like every other pane var instead of adding a second mechanism.
6
6
  *
7
7
  * AGENT panes only — the executor's per-run tab and its layout panes. NOT the
@@ -9,5 +9,5 @@
9
9
  * `docs/conductor/node.md` § Agent-pane shell marker.
10
10
  */
11
11
  export declare const AGENT_SHELL_ENV: Record<string, string>;
12
- /** BB_* env vars as `--env KEY=VALUE` args (never dump the full environment). */
12
+ /** BAKERS_* (and the internal BB_* hand-offs) env vars as `--env KEY=VALUE` args (never dump the full environment). */
13
13
  export declare function envArgs(env: Record<string, string | undefined>): string[];
package/dist/src/panes.js CHANGED
@@ -3,7 +3,7 @@
3
3
  /**
4
4
  * Marker exported into an AGENT pane's interactive shell, so a user's opt-in
5
5
  * shell init can recognise an agent-run pane at startup and isolate its history
6
- * (BB-64). It is a plain `BB_*` env entry on purpose: it rides {@link envArgs}
6
+ * (BB-64). It is a plain `BAKERS_*` env entry on purpose: it rides {@link envArgs}
7
7
  * like every other pane var instead of adding a second mechanism.
8
8
  *
9
9
  * AGENT panes only — the executor's per-run tab and its layout panes. NOT the
@@ -11,13 +11,13 @@
11
11
  * `docs/conductor/node.md` § Agent-pane shell marker.
12
12
  */
13
13
  export const AGENT_SHELL_ENV = {
14
- BB_AGENT_SHELL: '1',
14
+ BAKERS_AGENT_SHELL: '1',
15
15
  };
16
- /** BB_* env vars as `--env KEY=VALUE` args (never dump the full environment). */
16
+ /** BAKERS_* (and the internal BB_* hand-offs) env vars as `--env KEY=VALUE` args (never dump the full environment). */
17
17
  export function envArgs(env) {
18
18
  const out = [];
19
19
  for (const [key, value] of Object.entries(env)) {
20
- if (key.startsWith('BB_') && value != null) {
20
+ if (/^(BAKERS|BB)_/.test(key) && value != null) {
21
21
  out.push('--env', `${key}=${value}`);
22
22
  }
23
23
  }
@@ -1,5 +1,5 @@
1
1
  import type { Preset } from '@bakers-build/conductor/contract';
2
2
  export declare const executors: Preset['executors'];
3
- export declare const workspaces: Preset['workspaces'];
3
+ export declare const worktrees: Preset['worktrees'];
4
4
  export declare const hooks: Preset['hooks'];
5
5
  export declare const scopes: Preset['scopes'];
@@ -4,7 +4,7 @@ export const executors = (acc, opts) => [
4
4
  ...acc,
5
5
  herdrExecutor(opts),
6
6
  ];
7
- export const workspaces = (acc, opts) => [
7
+ export const worktrees = (acc, opts) => [
8
8
  ...acc,
9
9
  herdrWorkspace(opts),
10
10
  ];
@@ -10,7 +10,7 @@ export type BaseRefGitExec = (args: string[]) => Promise<string>;
10
10
  * run starts from the pushed remote state, not the host's local branch.
11
11
  *
12
12
  * A ticket's `override` (its `origin/<base_branch>`) wins only when it resolves
13
- * on the remote after a fetch; otherwise the configured `baseBranch`, else the
13
+ * on the remote after a fetch; otherwise the configured `base_branch`, else the
14
14
  * upstream of the repo's HEAD (e.g. `origin/develop`). A repo with no upstream
15
15
  * yields `undefined`. Fetch failures are non-fatal (offline / unknown remote).
16
16
  */
@@ -11,7 +11,7 @@ export { validateBranch } from './workspace.js';
11
11
  * run starts from the pushed remote state, not the host's local branch.
12
12
  *
13
13
  * A ticket's `override` (its `origin/<base_branch>`) wins only when it resolves
14
- * on the remote after a fetch; otherwise the configured `baseBranch`, else the
14
+ * on the remote after a fetch; otherwise the configured `base_branch`, else the
15
15
  * upstream of the repo's HEAD (e.g. `origin/develop`). A repo with no upstream
16
16
  * yields `undefined`. Fetch failures are non-fatal (offline / unknown remote).
17
17
  */
@@ -65,9 +65,9 @@ export declare function herdrWorkspace(opts?: {
65
65
  * the main clone is derived from the git common dir (BB-177).
66
66
  */
67
67
  root?: string;
68
- worktreeDir?: string;
69
- baseBranch?: string;
70
- autoSetupMerge?: boolean;
68
+ worktree_dir?: string;
69
+ base_branch?: string;
70
+ auto_setup_merge?: boolean;
71
71
  /** Overrideable git exec for root derivation (tests). */
72
72
  execGit?: RootGitExec;
73
73
  /** Overrideable herdr exec (tests) — sibling of `execGit`. */
@@ -176,7 +176,7 @@ export class HerdrWorkspace {
176
176
  }
177
177
  export function herdrWorkspace(opts = {}) {
178
178
  return {
179
- kind: 'workspace',
179
+ kind: 'worktree',
180
180
  id: 'herdr',
181
181
  requiredModules: [],
182
182
  // `deps` carries the conductor logger, so teardown warnings are actually
@@ -188,10 +188,10 @@ export function herdrWorkspace(opts = {}) {
188
188
  });
189
189
  return new HerdrWorkspace({
190
190
  root,
191
- ...(opts.worktreeDir ? { worktreeDir: opts.worktreeDir } : {}),
192
- ...(opts.baseBranch ? { baseBranch: opts.baseBranch } : {}),
191
+ ...(opts.worktree_dir ? { worktreeDir: opts.worktree_dir } : {}),
192
+ ...(opts.base_branch ? { baseBranch: opts.base_branch } : {}),
193
193
  ...(opts.execHerdr ? { execHerdr: opts.execHerdr } : {}),
194
- ...(opts.autoSetupMerge ? { autoSetupMerge: true } : {}),
194
+ ...(opts.auto_setup_merge ? { autoSetupMerge: true } : {}),
195
195
  ...(deps?.logger ? { logger: deps.logger } : {}),
196
196
  });
197
197
  },
@@ -0,0 +1,119 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://bakers.build/schema/addon-herdr/options.schema.json",
4
+ "title": "herdr executor + worktree options",
5
+ "type": "object",
6
+ "properties": {
7
+ "command": {
8
+ "type": "string",
9
+ "description": "Fallback agent command when the conductor supplies none. Default `claude`."
10
+ },
11
+ "open": {
12
+ "type": "object",
13
+ "description": "Startup layout of a fresh worktree; `{}` opts out. Templates expand {identifier}, {branch}, {title}, {worktree_path}.",
14
+ "properties": {
15
+ "command": {
16
+ "type": "string"
17
+ },
18
+ "panes": {
19
+ "type": "array",
20
+ "items": {
21
+ "$ref": "#/$defs/pane"
22
+ }
23
+ },
24
+ "tab_label": {
25
+ "type": "string"
26
+ },
27
+ "panel_label": {
28
+ "type": "string"
29
+ }
30
+ },
31
+ "additionalProperties": false
32
+ },
33
+ "root": {
34
+ "type": "string",
35
+ "description": "Main clone; otherwise derived from the git common dir."
36
+ },
37
+ "default": {
38
+ "$ref": "#/$defs/state"
39
+ },
40
+ "states": {
41
+ "type": "object",
42
+ "additionalProperties": {
43
+ "$ref": "#/$defs/state"
44
+ }
45
+ },
46
+ "launch_watch": {
47
+ "type": "object",
48
+ "description": "Launch-watch windows: wait start_timeout_ms (default 60000) for the wrapper to start, then timeout_ms (default 4000) in which an immediate agent exit fails the launch.",
49
+ "properties": {
50
+ "timeout_ms": {
51
+ "type": "integer",
52
+ "minimum": 0
53
+ },
54
+ "start_timeout_ms": {
55
+ "type": "integer",
56
+ "minimum": 0
57
+ },
58
+ "poll_ms": {
59
+ "type": "integer",
60
+ "minimum": 0
61
+ }
62
+ },
63
+ "additionalProperties": false
64
+ },
65
+ "worktree_dir": {
66
+ "type": "string",
67
+ "description": "Directory (relative to root, or absolute) for new worktrees. Default `.bakers-worktrees`."
68
+ },
69
+ "base_branch": {
70
+ "type": "string",
71
+ "description": "Base ref for new branches. Default: the upstream of the root's HEAD."
72
+ },
73
+ "auto_setup_merge": {
74
+ "type": "boolean",
75
+ "description": "`true` leaves Git's branch.autoSetupMerge alone. Default `false`."
76
+ }
77
+ },
78
+ "additionalProperties": false,
79
+ "$defs": {
80
+ "pane": {
81
+ "type": "object",
82
+ "properties": {
83
+ "direction": {
84
+ "enum": ["right", "down"]
85
+ },
86
+ "command": {
87
+ "type": "string"
88
+ },
89
+ "focus": {
90
+ "type": "boolean"
91
+ }
92
+ },
93
+ "required": ["direction", "command"],
94
+ "additionalProperties": false
95
+ },
96
+ "state": {
97
+ "type": "object",
98
+ "description": "Per-state layout. Templates expand {identifier}, {title}, {title_slug}, {run_uuid}, {workspace_path}.",
99
+ "properties": {
100
+ "tab_label": {
101
+ "type": "string"
102
+ },
103
+ "workspace_label": {
104
+ "type": "string"
105
+ },
106
+ "panel_label": {
107
+ "type": "string"
108
+ },
109
+ "panes": {
110
+ "type": "array",
111
+ "items": {
112
+ "$ref": "#/$defs/pane"
113
+ }
114
+ }
115
+ },
116
+ "additionalProperties": false
117
+ }
118
+ }
119
+ }
package/package.json CHANGED
@@ -1,16 +1,18 @@
1
1
  {
2
2
  "name": "@bakers-build/addon-herdr",
3
- "version": "0.7.1-next.7",
3
+ "version": "0.8.1-next.1",
4
4
  "description": "bakers.build herdr integration: spawn executor + per-ticket worktree workspace.",
5
5
  "type": "module",
6
6
  "license": "MIT",
7
7
  "exports": {
8
8
  ".": "./dist/src/index.js",
9
9
  "./preset": "./dist/src/preset.js",
10
- "./shared": "./dist/src/shared.js"
10
+ "./shared": "./dist/src/shared.js",
11
+ "./options.schema.json": "./options.schema.json"
11
12
  },
12
13
  "files": [
13
- "dist/src"
14
+ "dist/src",
15
+ "options.schema.json"
14
16
  ],
15
17
  "publishConfig": {
16
18
  "access": "public"
@@ -21,14 +23,14 @@
21
23
  "directory": "bakers-cli/addons/herdr"
22
24
  },
23
25
  "dependencies": {
24
- "@bakers-build/addon-workspace-git": "^0.7.1-next.7"
26
+ "@bakers-build/addon-workspace-git": "^0.8.1-next.1"
25
27
  },
26
28
  "peerDependencies": {
27
- "@bakers-build/conductor": "^0.7.1-next.7",
28
- "@bakers-build/core": "^0.7.1-next.7"
29
+ "@bakers-build/conductor": "^0.8.1-next.1",
30
+ "@bakers-build/core": "^0.8.1-next.1"
29
31
  },
30
32
  "bakersBuild": {
31
- "commit": "082d8c57436f78e751f5a9a26a4446cec42209ce",
33
+ "commit": "c4a887bee37bb2fed14bb9ba15ad0aacf0e26f7e",
32
34
  "channel": "next"
33
35
  }
34
36
  }