Make pi-loop an installable CLI (Phase 1: maintainer-only local install) #25

Closed
opened 2026-07-27 00:31:29 +00:00 by david · 0 comments
Owner

Package pi-loop so it installs as a real global pi-loop command, mirroring how pi
itself is packaged (tsc → dist). Phase 1 is maintainer-only local install via
npm i -g .; publishing to Verdaccio is deferred to Phase 2.

See docs/implementation-plan-installable-cli.md for the full plan.

Scope (Phase 1)

  • M1 — Emit compiled JS: add tsconfig.build.json (outDir: dist), build = tsc -p tsconfig.build.json, keep a typecheck script.
  • M2 — Repoint entrypoint: bindist/cli.js; shebang → #!/usr/bin/env node; ensure dist/cli.js is executable.
  • M3 — Package hygiene: add files allowlist (dist, README); add prepare build hook; verify .pi-loop/ and src/ absent via npm pack --dry-run.
  • M4 — Add install:local script (build + npm i -g .); keep tsx/npm start dev workflow.
  • M5 — Update README.md: Install (incl. reinstall-to-update), Development (tsx), Prerequisites, Phase 2 roadmap note.

Acceptance ("done")

Full end-to-end run of the installed pi-loop (no tsx/npx) from an unrelated target
repo against a real/sandbox issue produces a Draft MR. Plus: npm run build emits
dist/, npm i -g . succeeds, and npm pack --dry-run excludes .pi-loop//src/.

Out of scope (Phase 2)

Package scope/name, publish automation (manual vs CI), and Verdaccio .npmrc/auth.

Package pi-loop so it installs as a real global `pi-loop` command, mirroring how pi itself is packaged (`tsc → dist`). Phase 1 is maintainer-only local install via `npm i -g .`; publishing to Verdaccio is deferred to Phase 2. See `docs/implementation-plan-installable-cli.md` for the full plan. ## Scope (Phase 1) - [ ] M1 — Emit compiled JS: add `tsconfig.build.json` (`outDir: dist`), `build` = `tsc -p tsconfig.build.json`, keep a `typecheck` script. - [ ] M2 — Repoint entrypoint: `bin` → `dist/cli.js`; shebang → `#!/usr/bin/env node`; ensure `dist/cli.js` is executable. - [ ] M3 — Package hygiene: add `files` allowlist (`dist`, README); add `prepare` build hook; verify `.pi-loop/` and `src/` absent via `npm pack --dry-run`. - [ ] M4 — Add `install:local` script (build + `npm i -g .`); keep `tsx`/`npm start` dev workflow. - [ ] M5 — Update README.md: Install (incl. reinstall-to-update), Development (tsx), Prerequisites, Phase 2 roadmap note. ## Acceptance ("done") Full end-to-end run of the **installed** `pi-loop` (no tsx/npx) from an unrelated target repo against a real/sandbox issue produces a **Draft MR**. Plus: `npm run build` emits `dist/`, `npm i -g .` succeeds, and `npm pack --dry-run` excludes `.pi-loop/`/`src/`. ## Out of scope (Phase 2) Package scope/name, publish automation (manual vs CI), and Verdaccio `.npmrc`/auth.
david closed this issue 2026-07-27 02:50:30 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
david/pi-loop#25
No description provided.