@a5c-ai/babysitter-github 5.0.1-staging.e4f17eff → 5.0.1-staging.f01483e80761

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 (52) hide show
  1. package/README.md +33 -25
  2. package/bin/cli.js +14 -26
  3. package/bin/install-shared.js +398 -215
  4. package/bin/install.js +49 -89
  5. package/bin/uninstall.js +30 -60
  6. package/commands/call.md +5 -1
  7. package/commands/cleanup.md +30 -8
  8. package/commands/doctor.md +7 -8
  9. package/commands/help.md +245 -244
  10. package/commands/observe.md +12 -12
  11. package/commands/yolo.md +11 -7
  12. package/hooks/babysitter-proxied-post-tool-use.ps1 +12 -0
  13. package/hooks/babysitter-proxied-post-tool-use.sh +3 -0
  14. package/hooks/babysitter-proxied-pre-compact.ps1 +12 -0
  15. package/hooks/babysitter-proxied-pre-compact.sh +3 -0
  16. package/hooks/babysitter-proxied-pre-tool-use.ps1 +12 -0
  17. package/hooks/babysitter-proxied-pre-tool-use.sh +3 -0
  18. package/hooks/babysitter-proxied-session-end.ps1 +10 -114
  19. package/hooks/babysitter-proxied-session-end.sh +2 -111
  20. package/hooks/babysitter-proxied-session-start.ps1 +10 -187
  21. package/hooks/babysitter-proxied-session-start.sh +6 -168
  22. package/hooks/babysitter-proxied-user-prompt-submitted.ps1 +10 -90
  23. package/hooks/babysitter-proxied-user-prompt-submitted.sh +2 -86
  24. package/hooks.json +33 -9
  25. package/package.json +20 -21
  26. package/plugin.json +7 -6
  27. package/scripts/create-release-tag.mjs +18 -0
  28. package/scripts/publish-from-tag.mjs +41 -0
  29. package/scripts/team-install.js +14 -84
  30. package/skills/call/SKILL.md +5 -1
  31. package/skills/cleanup/SKILL.md +43 -0
  32. package/skills/contrib/SKILL.md +34 -0
  33. package/skills/doctor/SKILL.md +7 -8
  34. package/skills/forever/SKILL.md +8 -0
  35. package/skills/help/SKILL.md +3 -2
  36. package/skills/observe/SKILL.md +1 -1
  37. package/skills/plugins/SKILL.md +257 -0
  38. package/skills/project-install/SKILL.md +18 -0
  39. package/skills/resume/SKILL.md +1 -1
  40. package/skills/retrospect/SKILL.md +48 -48
  41. package/skills/user-install/SKILL.md +3 -3
  42. package/skills/yolo/SKILL.md +12 -0
  43. package/versions.json +2 -1
  44. package/.github/plugin.json +0 -25
  45. package/hooks/proxied-hooks.json +0 -29
  46. package/hooks/session-end.ps1 +0 -69
  47. package/hooks/session-end.sh +0 -54
  48. package/hooks/session-start.ps1 +0 -111
  49. package/hooks/session-start.sh +0 -101
  50. package/hooks/user-prompt-submitted.ps1 +0 -52
  51. package/hooks/user-prompt-submitted.sh +0 -31
  52. package/scripts/sync-command-surfaces.js +0 -62
package/README.md CHANGED
@@ -18,7 +18,8 @@ directly.
18
18
  - **Node.js 22+**
19
19
  - **GitHub Copilot CLI** (`copilot`) -- requires an active GitHub Copilot
20
20
  subscription
21
- - **Babysitter SDK CLI** (`@a5c-ai/babysitter-sdk`) -- installed globally
21
+ - **Babysitter CLI** (`@a5c-ai/babysitter`) -- installed globally when using
22
+ the SDK helper
22
23
 
23
24
  ## Installation
24
25
 
@@ -28,7 +29,7 @@ Register the a5c.ai marketplace and install the plugin:
28
29
 
29
30
  ```bash
30
31
  # Register the marketplace
31
- copilot plugin marketplace add a5c-ai/babysitter
32
+ copilot plugin marketplace add a5c-ai/babysitter-claude
32
33
 
33
34
  # Install the plugin
34
35
  copilot plugin install babysitter
@@ -36,42 +37,50 @@ copilot plugin install babysitter
36
37
 
37
38
  ### Direct GitHub install
38
39
 
39
- Install directly from the Git repository using Copilot CLI. Copilot CLI
40
- discovers the plugin via `.github/plugin/marketplace.json` at the repo root:
40
+ Install directly from the generated external plugin repository:
41
41
 
42
42
  ```bash
43
- copilot plugin install a5c-ai/babysitter
43
+ copilot plugin install a5c-ai/babysitter-github-copilot
44
44
  ```
45
45
 
46
- ### Alternative Installation (npm / development)
46
+ ### Alternative Installation (SDK helper / development)
47
47
 
48
- For development or environments where the Copilot CLI plugin system is not
49
- available, install via npm:
48
+ For development, automation, or environments where the Copilot CLI plugin system is not available, install through the Babysitter SDK helper. This is the canonical scriptable path used by the installer tests and resolves to `npx --yes @a5c-ai/babysitter-github install ...` under the hood:
50
49
 
51
- Install the SDK CLI first:
50
+ Install the Babysitter CLI first:
52
51
 
53
52
  ```bash
54
- npm install -g @a5c-ai/babysitter-sdk
53
+ npm install -g @a5c-ai/babysitter
55
54
  ```
56
55
 
57
- Then install the GitHub Copilot plugin globally:
56
+ Then install the GitHub Copilot plugin globally or into a workspace:
58
57
 
59
58
  ```bash
60
- npm install -g @a5c-ai/babysitter-github
61
- babysitter-github install
59
+ # Global install
60
+ babysitter harness:install-plugin github-copilot
61
+
62
+ # Workspace install
63
+ babysitter harness:install-plugin github-copilot --workspace /path/to/repo
62
64
  ```
63
65
 
64
- Or install from source:
66
+ You can also run the published package installer directly:
65
67
 
66
68
  ```bash
67
- cd plugins/babysitter-github
68
- node bin/install.js
69
+ npx --yes @a5c-ai/babysitter-github install --global
70
+ npx --yes @a5c-ai/babysitter-github install --workspace /path/to/repo
71
+ ```
72
+
73
+ Or install from generated source:
74
+
75
+ ```bash
76
+ npm run generate:plugins
77
+ node artifacts/generated-plugins/github-copilot/bin/install.js
69
78
  ```
70
79
 
71
- Install into a specific workspace:
80
+ Install into a specific workspace from generated source:
72
81
 
73
82
  ```bash
74
- babysitter-github install --workspace /path/to/repo
83
+ node artifacts/generated-plugins/github-copilot/bin/install.js --workspace /path/to/repo
75
84
  ```
76
85
 
77
86
  ### GitHub Copilot cloud agent installation
@@ -253,8 +262,7 @@ Copilot CLI looks for the plugin manifest in these paths, checked in order:
253
262
  The first match wins. This plugin uses `plugin.json` at the package root.
254
263
 
255
264
  For marketplace discovery, Copilot CLI looks for `.github/plugin/marketplace.json`
256
- at the repository root. This file lists all available plugins in the repo and is
257
- used when installing via `copilot plugin install OWNER/REPO`.
265
+ at the repository root of the generated plugin repository.
258
266
 
259
267
  ### plugin.json Schema
260
268
 
@@ -404,7 +412,7 @@ repository root in `.github/plugin/marketplace.json`:
404
412
  "name": "babysitter",
405
413
  "description": "Multi-step workflow orchestration with event-sourced state",
406
414
  "version": "0.1.0",
407
- "source": "./plugins/babysitter-github"
415
+ "source": "./"
408
416
  }
409
417
  ]
410
418
  }
@@ -461,7 +469,7 @@ These registries are available without running `marketplace add`.
461
469
  ## Plugin Structure (Directory Layout)
462
470
 
463
471
  ```
464
- plugins/babysitter-github/
472
+ artifacts/generated-plugins/github-copilot/
465
473
  plugin.json # Plugin manifest (skills, hooks, metadata)
466
474
  .github/plugin.json # Plugin manifest (alternate discovery path)
467
475
  hooks.json # Hook configuration (sessionStart, sessionEnd, userPromptSubmitted)
@@ -579,14 +587,14 @@ compatibility where PowerShell execution is available.
579
587
  git clone https://github.com/a5c-ai/babysitter.git
580
588
  cd babysitter
581
589
  npm install
582
- cd plugins/babysitter-github
590
+ npm run generate:plugins
583
591
  node bin/install.js
584
592
  ```
585
593
 
586
594
  ### Publishing
587
595
 
588
596
  ```bash
589
- cd plugins/babysitter-github
597
+ cd artifacts/generated-plugins/github-copilot
590
598
  npm run deploy # Publish to npm (public)
591
599
  npm run deploy:staging # Publish to npm with staging tag
592
600
  ```
@@ -594,7 +602,7 @@ npm run deploy:staging # Publish to npm with staging tag
594
602
  ### Team installation
595
603
 
596
604
  ```bash
597
- cd plugins/babysitter-github
605
+ cd artifacts/generated-plugins/github-copilot
598
606
  npm run team:install
599
607
  ```
600
608
 
package/bin/cli.js CHANGED
@@ -5,13 +5,14 @@ const path = require('path');
5
5
  const { spawnSync } = require('child_process');
6
6
 
7
7
  const PACKAGE_ROOT = path.resolve(__dirname, '..');
8
+ let shared;
9
+ try { shared = require('./install-shared'); } catch {}
8
10
 
9
11
  function printUsage() {
10
12
  console.error([
11
13
  'Usage:',
12
14
  ' babysitter-github install [--global]',
13
15
  ' babysitter-github install --workspace [path]',
14
- ' babysitter-github install --cloud-agent [--workspace [path]]',
15
16
  ' babysitter-github uninstall',
16
17
  ].join('\n'));
17
18
  }
@@ -19,22 +20,15 @@ function printUsage() {
19
20
  function parseInstallArgs(argv) {
20
21
  let scope = 'global';
21
22
  let workspace = null;
22
- let cloudAgent = false;
23
23
  const passthrough = [];
24
24
 
25
25
  for (let i = 0; i < argv.length; i += 1) {
26
26
  const arg = argv[i];
27
27
  if (arg === '--global') {
28
- if (scope === 'workspace') {
29
- throw new Error('install accepts either --global or --workspace, not both');
30
- }
31
28
  scope = 'global';
32
29
  continue;
33
30
  }
34
31
  if (arg === '--workspace') {
35
- if (scope === 'global' && workspace !== null) {
36
- throw new Error('install accepts either --global or --workspace, not both');
37
- }
38
32
  scope = 'workspace';
39
33
  const next = argv[i + 1];
40
34
  if (next && !next.startsWith('-')) {
@@ -45,30 +39,17 @@ function parseInstallArgs(argv) {
45
39
  }
46
40
  continue;
47
41
  }
48
- if (arg === '--cloud-agent') {
49
- cloudAgent = true;
50
- passthrough.push(arg);
51
- continue;
52
- }
53
42
  passthrough.push(arg);
54
43
  }
55
44
 
56
- return {
57
- cloudAgent,
58
- scope,
59
- workspace,
60
- passthrough,
61
- };
45
+ return { scope, workspace, passthrough };
62
46
  }
63
47
 
64
48
  function runNodeScript(scriptPath, args, extraEnv = {}) {
65
49
  const result = spawnSync(process.execPath, [scriptPath, ...args], {
66
50
  cwd: process.cwd(),
67
51
  stdio: 'inherit',
68
- env: {
69
- ...process.env,
70
- ...extraEnv,
71
- },
52
+ env: { ...process.env, ...extraEnv },
72
53
  });
73
54
  process.exitCode = result.status ?? 1;
74
55
  }
@@ -82,9 +63,16 @@ function main() {
82
63
  }
83
64
 
84
65
  if (command === 'install') {
66
+ if (shared && typeof shared.harnessCliRoute === 'function' && shared.harnessCliRoute(rest, PACKAGE_ROOT, runNodeScript)) {
67
+ return;
68
+ }
85
69
  const parsed = parseInstallArgs(rest);
86
- if (parsed.cloudAgent) {
87
- runNodeScript(path.join(PACKAGE_ROOT, 'bin', 'install.js'), parsed.passthrough);
70
+ if (parsed.passthrough.includes('--cloud-agent')) {
71
+ const args = [...parsed.passthrough];
72
+ if (parsed.workspace) {
73
+ args.push('--workspace', parsed.workspace);
74
+ }
75
+ runNodeScript(path.join(PACKAGE_ROOT, 'bin', 'install.js'), args);
88
76
  return;
89
77
  }
90
78
  if (parsed.scope === 'workspace') {
@@ -96,7 +84,7 @@ function main() {
96
84
  runNodeScript(
97
85
  path.join(PACKAGE_ROOT, 'scripts', 'team-install.js'),
98
86
  args,
99
- { BABYSITTER_PACKAGE_ROOT: PACKAGE_ROOT },
87
+ { PLUGIN_PACKAGE_ROOT: PACKAGE_ROOT },
100
88
  );
101
89
  return;
102
90
  }