Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
contents: write
pull-requests: read
with:
service-name: "@photon-ai/photon"
service-name: "@photon-ai/cli"
build-command: "bun run build"
release: ${{ github.event_name == 'workflow_dispatch' && inputs.release || false }}
dry-run: ${{ github.event_name == 'workflow_dispatch' && inputs['dry-run'] || false }}
Expand Down
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
Typed terminal UI for the [Photon Dashboard](https://photon.codes). Replaces the web UI for everyday work — manage projects, Spectrum users / lines / platforms, billing, and your developer profile from a terminal.

```sh
npx @photon-ai/photon login # try it without installing
bun add -g @photon-ai/photon # or install for daily use
npx @photon-ai/cli login # try it without installing
bun add -g @photon-ai/cli # or install for daily use
```

---
Expand All @@ -16,8 +16,8 @@ Three options. Pick whichever fits.
### 1. One-off — no install (`npx` / `bunx`)

```sh
npx @photon-ai/photon login
bunx @photon-ai/photon projects ls
npx @photon-ai/cli login
bunx @photon-ai/cli projects ls
```

Each invocation pulls the latest release on demand. Good for scripts, throwaway machines, or trying the CLI before committing. Requires Bun on `PATH` (the bundle has a `#!/usr/bin/env bun` shebang) — install it once with:
Expand All @@ -29,7 +29,7 @@ curl -fsSL https://bun.sh/install | bash
### 2. Global install — daily use (`bun add -g`)

```sh
bun add -g @photon-ai/photon
bun add -g @photon-ai/cli
photon login
```

Expand Down
6 changes: 4 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "@photon-ai/photon",
"name": "@photon-ai/cli",
"version": "0.1.3",
"description": "Photon CLI — typed terminal UI for the Photon Dashboard. Binary: `photon` (alias `pho`).",
"keywords": [
Expand All @@ -21,7 +21,9 @@
"url": "https://github.com/photon-hq/cli/issues"
},
"type": "module",
"bin": "./dist/photon.js",
"bin": {
"photon": "./dist/photon.js"
},
"files": [
"dist",
"README.md"
Expand Down
3 changes: 2 additions & 1 deletion src/lib/pho-alias.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,8 @@ import { join, resolve, sep } from "node:path";
*
* Why not declare both bins in package.json? npm 11's `npx <scoped-pkg>`
* (no version) skips bin auto-resolve when `bin` has multiple keys. Keeping
* `bin` as a single string preserves clean `npx @photon-ai/photon` usage.
* `bin` as a single entry (`{ photon: "./dist/photon.js" }`) preserves clean
* `npx @photon-ai/cli` usage.
*
* Why not a `postinstall` script? Bun blocks postinstall by default — that
* would silently strip `pho` from `bun add -g` (our primary install path).
Expand Down