@betterborg/cli 0.1.0 → 0.1.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.
package/LICENSE CHANGED
@@ -1,6 +1,6 @@
1
1
  MIT License
2
2
 
3
- Copyright (c) 2026 BetterBorg
3
+ Copyright (c) 2026 Betterborg
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  of this software and associated documentation files (the "Software"), to deal
package/NOTICE CHANGED
@@ -1,7 +1,7 @@
1
- BetterBorg CLI
2
- Copyright 2026 BetterBorg
1
+ Betterborg CLI
2
+ Copyright 2026 Betterborg
3
3
 
4
- This product includes software developed by BetterBorg
4
+ This product includes software developed by Betterborg
5
5
  (https://github.com/betterborg).
6
6
 
7
- BetterBorg CLI is distributed under the MIT License. See LICENSE.
7
+ Betterborg CLI is distributed under the MIT License. See LICENSE.
package/README.md ADDED
@@ -0,0 +1,76 @@
1
+ # @betterborg/cli
2
+
3
+ Betterborg is an AI engineering team for substantial software projects, not a chat window that makes an isolated edit. You give it a task or a PRD; agents investigate your real code, write a reviewed technical plan, decompose it into a dependency graph of tasks, and implement them, each in its own isolated Git worktree. You approve the plan before anything is decomposed, and the estimate before anything runs. It works locally, on your own Claude Code or Codex subscription.
4
+
5
+ > [!NOTE]
6
+ > Pre-alpha. Interfaces may change between releases.
7
+
8
+ This package is a launcher, not the CLI itself. It resolves a `betterborg` matching its own version, then forwards your arguments, stdio, and signals to it. Nothing is downloaded at install time.
9
+
10
+ ## Try it
11
+
12
+ ```bash
13
+ npx --yes @betterborg/cli version
14
+ ```
15
+
16
+ ## Install
17
+
18
+ ```bash
19
+ npm install --global @betterborg/cli
20
+ ```
21
+
22
+ Then activate the agent-host integrations, which need a persistent install rather than `npx`:
23
+
24
+ ```bash
25
+ betterborg plugins install --all
26
+ ```
27
+
28
+ Run `/reload-plugins` in any open Claude Code session, and start a new Codex session when prompted.
29
+
30
+ From inside a Git repository, run the loop:
31
+
32
+ ```bash
33
+ betterborg trust # trust this worktree (machine-local)
34
+ betterborg init # register and analyze the repository
35
+ betterborg create my-feature # or: betterborg create my-feature --prd spec.md
36
+ betterborg plan start my-feature # agents plan, review, and iterate
37
+ betterborg plan approve my-feature # your gate: nothing is decomposed before this
38
+ betterborg task estimate my-feature # P50/P80 work and cost
39
+ betterborg execute my-feature # approve the estimate, then run
40
+ ```
41
+
42
+ `betterborg execute` hands off reviewed local branches. Add `--push` or `--pr` to publish them. `betterborg --help` is the full command index.
43
+
44
+ ## How the launcher finds the CLI
45
+
46
+ On each run, in order:
47
+
48
+ 1. **An installed `betterborg` on `PATH`**, if `betterborg version` reports this package's exact version. A `pip install betterborg` or the standalone installer takes over from here, and the launcher adds nothing.
49
+ 2. **The standalone release binary** for macOS and Linux on arm64 or x86_64. It is fetched from the matching GitHub release, verified against the published SHA-256 digest, and cached under `$XDG_CACHE_HOME/betterborg/cli/<version>`, or `~/.cache/betterborg/cli/<version>`, so later runs reuse it. A binary that fails verification is discarded, never executed.
50
+ 3. **`uvx --from betterborg==<version> betterborg`**, if [uv](https://docs.astral.sh/uv/) is on `PATH`.
51
+
52
+ If none of those resolve, the launcher exits with what it tried and how to fix it.
53
+
54
+ ## Requirements
55
+
56
+ - Node.js 18+ to run the launcher.
57
+ - macOS or Linux. On Windows, use a WSL2 shell.
58
+ - One agent transport: a `claude` or `codex` CLI on `PATH` and **already logged in**, or `ANTHROPIC_API_KEY` / `OPENAI_API_KEY` exported in your shell.
59
+
60
+ Step 3 additionally needs Python 3.11+, which `uv` will provide.
61
+
62
+ Keep provider keys in your shell or a secret manager, never in `.betterborg/config.toml` or any tracked file.
63
+
64
+ ## Documentation
65
+
66
+ - [Installation guide](https://github.com/betterborg/betterborg-cli/blob/main/docs/installation.md): version pinning, WSL2, providers, recovery
67
+ - [Command guide](https://github.com/betterborg/betterborg-cli/blob/main/docs/commands.md): bootstrap and initialization
68
+ - [Repository](https://github.com/betterborg/betterborg-cli)
69
+
70
+ ## Reporting bugs
71
+
72
+ File a [GitHub issue](https://github.com/betterborg/betterborg-cli/issues).
73
+
74
+ ## License
75
+
76
+ Copyright 2026 Betterborg. Licensed under the [MIT License](https://github.com/betterborg/betterborg-cli/blob/main/LICENSE). See [NOTICE](https://github.com/betterborg/betterborg-cli/blob/main/NOTICE) for attribution.
package/lib/launcher.js CHANGED
@@ -18,7 +18,7 @@ function targetFor(platform, architecture) {
18
18
  if (!operatingSystem || !targetArchitecture) {
19
19
  return null;
20
20
  }
21
- return `borg-${operatingSystem}-${targetArchitecture}`;
21
+ return `betterborg-${operatingSystem}-${targetArchitecture}`;
22
22
  }
23
23
 
24
24
  function translateVersionArguments(arguments_) {
@@ -110,8 +110,8 @@ function launcherExecutables(dependencies) {
110
110
  }
111
111
  const names =
112
112
  dependencies.platform === "win32"
113
- ? ["borg", "borg.cmd", "borg.ps1"]
114
- : ["borg"];
113
+ ? ["betterborg", "betterborg.cmd", "betterborg.ps1"]
114
+ : ["betterborg"];
115
115
  for (const shimDirectory of shimDirectories) {
116
116
  for (const name of names) {
117
117
  executables.push(dependencies.pathModule.resolve(shimDirectory, name));
@@ -158,7 +158,7 @@ function executableOnPath(name, dependencies, excludedPaths = []) {
158
158
 
159
159
  function installedCli(version, dependencies) {
160
160
  const candidate = executableOnPath(
161
- "borg",
161
+ "betterborg",
162
162
  dependencies,
163
163
  launcherExecutables(dependencies),
164
164
  );
@@ -182,7 +182,7 @@ function installedCli(version, dependencies) {
182
182
  );
183
183
  if (
184
184
  completed.status === 0 &&
185
- completed.stdout.trim() === `borg ${version}`
185
+ completed.stdout.trim() === `betterborg ${version}`
186
186
  ) {
187
187
  return candidate;
188
188
  }
@@ -317,7 +317,7 @@ async function resolveCli(version, overrides = {}) {
317
317
  if (uvx) {
318
318
  return {
319
319
  command: uvx,
320
- argumentsPrefix: ["--from", `betterborg==${version}`, "borg"],
320
+ argumentsPrefix: ["--from", `betterborg==${version}`, "betterborg"],
321
321
  source: "uvx",
322
322
  };
323
323
  }
@@ -326,7 +326,7 @@ async function resolveCli(version, overrides = {}) {
326
326
  ? `could not install the ${target} release${releaseFailure ? ` (${releaseFailure})` : ""}`
327
327
  : `no standalone release supports ${dependencies.platform}/${dependencies.architecture}`;
328
328
  throw new Error(
329
- `${targetDescription}, and uvx is not on PATH. Install uv from https://docs.astral.sh/uv/ or install betterborg==${version} so borg is on PATH.`,
329
+ `${targetDescription}, and uvx is not on PATH. Install uv from https://docs.astral.sh/uv/ or install betterborg==${version} so betterborg is on PATH.`,
330
330
  );
331
331
  }
332
332
 
@@ -373,7 +373,7 @@ function launch(resolved, arguments_, overrides = {}) {
373
373
  if (settled) return;
374
374
  settled = true;
375
375
  cleanup();
376
- reject(new Error(`could not start BetterBorg CLI: ${error.message}`));
376
+ reject(new Error(`could not start Betterborg CLI: ${error.message}`));
377
377
  });
378
378
  child.once("close", (code, signal) => {
379
379
  if (settled) return;
@@ -405,7 +405,7 @@ function reportFailure(error, dependencies = {}) {
405
405
  const logger = dependencies.console || console;
406
406
  const processLike = dependencies.process || process;
407
407
  const message = error instanceof Error ? error.message : String(error);
408
- logger.error(`borg: ${message}`);
408
+ logger.error(`betterborg: ${message}`);
409
409
  processLike.exitCode = 1;
410
410
  }
411
411
 
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@betterborg/cli",
3
- "version": "0.1.0",
4
- "description": "Installer and launcher for the BetterBorg CLI",
3
+ "version": "0.1.1",
4
+ "description": "Installer and launcher for the Betterborg CLI",
5
5
  "license": "MIT",
6
6
  "repository": {
7
7
  "type": "git",
@@ -12,11 +12,12 @@
12
12
  "bugs": "https://github.com/betterborg/betterborg-cli/issues",
13
13
  "type": "commonjs",
14
14
  "bin": {
15
- "borg": "bin/borg.js"
15
+ "betterborg": "bin/betterborg.js"
16
16
  },
17
17
  "files": [
18
18
  "LICENSE",
19
19
  "NOTICE",
20
+ "README.md",
20
21
  "bin",
21
22
  "lib"
22
23
  ],
@@ -27,7 +28,7 @@
27
28
  "access": "public"
28
29
  },
29
30
  "scripts": {
30
- "lint": "node --check bin/borg.js && node --check lib/launcher.js && node --check test/launcher.test.js",
31
+ "lint": "node --check bin/betterborg.js && node --check lib/launcher.js && node --check test/launcher.test.js",
31
32
  "test": "node --test test/launcher.test.js"
32
33
  }
33
34
  }
File without changes