goalbuddy 0.2.14 → 0.2.15

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.
@@ -11,7 +11,7 @@
11
11
  "path": "./plugins/goalbuddy"
12
12
  },
13
13
  "policy": {
14
- "installation": "AVAILABLE",
14
+ "installation": "INSTALLED_BY_DEFAULT",
15
15
  "authentication": "ON_INSTALL"
16
16
  },
17
17
  "category": "Coding"
package/README.md CHANGED
@@ -22,7 +22,13 @@ GoalBuddy is a local Codex companion for work that is too broad to trust to a si
22
22
  npx goalbuddy
23
23
  ```
24
24
 
25
- Then invoke the installed skill inside Codex:
25
+ Or install it globally:
26
+
27
+ ```bash
28
+ npm i -g goalbuddy
29
+ ```
30
+
31
+ Then restart Codex and invoke the installed skill:
26
32
 
27
33
  ```text
28
34
  $goalbuddy
@@ -30,12 +36,6 @@ $goalbuddy
30
36
 
31
37
  `$goalbuddy` prepares the board and prints the `/goal` command to run next. It does not start `/goal` automatically.
32
38
 
33
- For native Codex plugin install instead of the skill-only installer:
34
-
35
- ```bash
36
- npx goalbuddy plugin install
37
- ```
38
-
39
39
  ## Why GoalBuddy Exists
40
40
 
41
41
  Long Codex goals drift. A request like "improve this project" can turn into unbounded edits, stale verification, and premature completion claims.
@@ -78,17 +78,18 @@ The default agents are installed with the skill:
78
78
 
79
79
  ## Install And Check Readiness
80
80
 
81
- Install or refresh the Codex skill and bundled agents:
81
+ Install and enable the native Codex plugin:
82
82
 
83
83
  ```bash
84
84
  npx goalbuddy
85
- npx goalbuddy update
85
+ npm i -g goalbuddy
86
86
  ```
87
87
 
88
- Install and enable the native Codex plugin:
88
+ Use the skill-only fallback if your Codex build does not support plugins:
89
89
 
90
90
  ```bash
91
- npx goalbuddy plugin install
91
+ npx goalbuddy install
92
+ npx goalbuddy update
92
93
  ```
93
94
 
94
95
  Native Codex `/goal` is still an under-development Codex feature. Before relying on the printed command, confirm your local Codex runtime is logged in and has goals enabled:
@@ -114,10 +115,10 @@ npx goalbuddy doctor
114
115
  Use a non-default Codex home:
115
116
 
116
117
  ```bash
117
- npx goalbuddy install --codex-home /path/to/.codex
118
+ npx goalbuddy --codex-home /path/to/.codex
118
119
  ```
119
120
 
120
- `install`, `update`, and `doctor` also support `--json` when an agent or script needs structured output.
121
+ `plugin install`, `install`, `update`, and `doctor` also support `--json` when an agent or script needs structured output.
121
122
 
122
123
  ## Run A Goal
123
124
 
@@ -44,7 +44,7 @@ const command = args[0] === "--help" || args[0] === "-h"
44
44
  ? "help"
45
45
  : args[0] && !args[0].startsWith("-")
46
46
  ? args[0]
47
- : "install";
47
+ : "default";
48
48
  const invokedAs = invokedCommandName();
49
49
 
50
50
  main().catch((error) => {
@@ -55,6 +55,9 @@ main().catch((error) => {
55
55
  async function main() {
56
56
  maybePrintLegacyNotice();
57
57
  switch (command) {
58
+ case "default":
59
+ installPlugin();
60
+ break;
58
61
  case "install":
59
62
  case "update":
60
63
  await installAll();
@@ -133,11 +136,12 @@ function usage() {
133
136
  console.log(`Codex ${canonicalProductName}
134
137
 
135
138
  Usage:
139
+ ${canonicalCliName} [--codex-home <path>] [--json]
140
+ ${canonicalCliName} plugin install [--source <marketplace-source>] [--codex-home <path>] [--json]
136
141
  ${canonicalCliName} install [--codex-home <path>] [--force] [--json]
137
142
  ${canonicalCliName} update [--codex-home <path>] [--json]
138
143
  ${canonicalCliName} agents [--codex-home <path>] [--force]
139
144
  ${canonicalCliName} doctor [--codex-home <path>] [--goal-ready]
140
- ${canonicalCliName} plugin install [--source <marketplace-source>] [--codex-home <path>] [--json]
141
145
  ${canonicalCliName} extend [--catalog-url <url-or-path>] [--kind <kind>] [--json]
142
146
  ${canonicalCliName} extend <id> [--catalog-url <url-or-path>] [--json]
143
147
  ${canonicalCliName} extend install <id> [--catalog-url <url-or-path>] [--dry-run] [--force] [--json]
@@ -145,7 +149,10 @@ Usage:
145
149
  ${canonicalCliName} extend doctor [<id>] [--codex-home <path>] [--json]
146
150
 
147
151
  Default:
148
- ${canonicalCliName} Installs the skill and bundled agent definitions.
152
+ ${canonicalCliName} Installs and enables the native Codex plugin.
153
+
154
+ Skill-only fallback:
155
+ ${canonicalCliName} install Installs the legacy skill payload and bundled agent definitions.
149
156
 
150
157
  Compatibility:
151
158
  ${legacyCliName} remains a temporary alias and prints the new npx command for human-facing use.
@@ -0,0 +1,29 @@
1
+ #!/usr/bin/env node
2
+ import { spawnSync } from "node:child_process";
3
+ import { dirname, join } from "node:path";
4
+ import { fileURLToPath } from "node:url";
5
+
6
+ const __dirname = dirname(fileURLToPath(import.meta.url));
7
+ const cliPath = join(__dirname, "goal-maker.mjs");
8
+ const globalInstall = process.env.npm_config_global === "true"
9
+ || process.env.npm_config_location === "global";
10
+
11
+ if (!globalInstall || process.env.GOALBUDDY_SKIP_POSTINSTALL) {
12
+ process.exit(0);
13
+ }
14
+
15
+ const result = spawnSync(process.execPath, [cliPath, "plugin", "install"], {
16
+ encoding: "utf8",
17
+ env: process.env,
18
+ stdio: "inherit",
19
+ });
20
+
21
+ if (result.status === 0) {
22
+ process.exit(0);
23
+ }
24
+
25
+ console.error("");
26
+ console.error("GoalBuddy installed globally, but Codex plugin setup did not complete.");
27
+ console.error("Run this after Codex is available:");
28
+ console.error(" goalbuddy");
29
+ process.exit(0);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "goalbuddy",
3
- "version": "0.2.14",
3
+ "version": "0.2.15",
4
4
  "description": "Turn open-ended Codex goals into a GoalBuddy Scout/Judge/Worker board with receipts, verification, and optional extensions.",
5
5
  "type": "module",
6
6
  "bin": {
@@ -21,9 +21,10 @@
21
21
  "goalbuddy/templates"
22
22
  ],
23
23
  "scripts": {
24
- "check": "node --check internal/cli/goal-maker.mjs goalbuddy/scripts/*.mjs && node --test internal/test/*.test.mjs",
24
+ "check": "node --check internal/cli/*.mjs goalbuddy/scripts/*.mjs && node --test internal/test/*.test.mjs",
25
25
  "test": "node --test internal/test/*.test.mjs",
26
26
  "pack:dry-run": "npm pack --dry-run",
27
+ "postinstall": "node internal/cli/postinstall.mjs",
27
28
  "publish:check": "node internal/cli/check-publish-version.mjs && npm run pack:dry-run",
28
29
  "prepublishOnly": "node internal/cli/check-publish-version.mjs"
29
30
  },
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "goalbuddy",
3
- "version": "0.2.14",
3
+ "version": "0.2.15",
4
4
  "description": "Turn broad Codex work into verified GoalBuddy boards with Scout, Judge, Worker, receipts, and optional extensions.",
5
5
  "author": {
6
6
  "name": "tolibear",
@@ -19,18 +19,24 @@ npx goalbuddy doctor
19
19
 
20
20
  ## Native Codex Install
21
21
 
22
- Install and enable the plugin with the GoalBuddy CLI:
22
+ Install and enable GoalBuddy:
23
23
 
24
24
  ```bash
25
- npx goalbuddy plugin install
25
+ npx goalbuddy
26
26
  ```
27
27
 
28
- This adds the `tolibear/goalbuddy` marketplace, caches the packaged plugin, and enables `goalbuddy@goalbuddy` for Codex. The npm CLI remains useful for `doctor`, project-local agent setup, and optional GoalBuddy extension management.
28
+ Or install the npm package globally:
29
+
30
+ ```bash
31
+ npm i -g goalbuddy
32
+ ```
33
+
34
+ The marketplace manifest is included for Codex discovery, but current Codex CLI builds only register the marketplace with `codex plugin marketplace add`; the npm CLI also caches and enables the plugin.
29
35
 
30
36
  For local CLI testing before npm publish:
31
37
 
32
38
  ```bash
33
- node internal/cli/goal-maker.mjs install --catalog-url extend/catalog.json
39
+ node internal/cli/goal-maker.mjs --catalog-url extend/catalog.json
34
40
  node internal/cli/goal-maker.mjs doctor
35
41
  ```
36
42