@tryarcanist/cli 0.1.400 → 0.1.401

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 (3) hide show
  1. package/README.md +21 -2
  2. package/dist/index.js +102 -85
  3. package/package.json +1 -1
package/README.md CHANGED
@@ -10,6 +10,25 @@ npm install -g @tryarcanist/cli
10
10
 
11
11
  Requires Node.js 22 or newer.
12
12
 
13
+ ## Onboard through your coding agent
14
+
15
+ Give your agent this prompt from a repository checkout:
16
+
17
+ > Install the latest @tryarcanist/cli and run `arcanist onboard --json`. Follow its next actions until this repository is ready and its first pull request review is verified. Show me approval links when needed; run the terminal commands yourself. Use `arcanist help onboard --json` for the full flow.
18
+
19
+ No Arcanist account or manually copied token is needed beforehand. New users approve sign-in in the browser; repository owners approve GitHub App installation when it is missing. Existing write-scoped CLI logins are reused. A browser-approved replacement supersedes a rejected or read-only project token for the same API; the project file stays unchanged. Explicit token overrides remain authoritative and must be replaced or unset if invalid. The agent resumes the same command after approval. Approval links carry a challenge, never the CLI token; the verifier and approved token stay in private files under `~/.arcanist`.
20
+
21
+ ```bash
22
+ arcanist onboard --json
23
+ arcanist onboard owner/repo --pr https://github.com/owner/repo/pull/123 --json
24
+ ```
25
+
26
+ Follow `command` to resume and `repository.nextAction` for setup interventions. `setup_pending` can be polled every five seconds. `repository_ready` means setup finished but the first review is still unverified: pass an existing PR with `--pr`. `review_pending` resumes the same review. Cancelled, rejected, or missing saved requests are cleared so the next invocation can retry. After new commits or an incomplete result, use `--pr <url> --restart-review` once to request verification again; resume with the returned command, which omits that flag. Only `complete` with `reviewVerified: true` proves a conclusive review of the returned `headSha`; findings do not make onboarding fail. `review_needs_attention` requires inspecting the incomplete result. Do not create a PR or change its code merely to finish onboarding.
27
+
28
+ Each repository needs its own environment for reviews. Appearing as a dependency in another repository’s workspace does not make it ready; onboarding prepares it separately.
29
+
30
+ For a setup question, pass its current ID to `arcanist environments answer owner/repo --question <id> --answer-stdin --json`. For requested credentials, pipe a JSON object of names and values to `arcanist environments secrets owner/repo --request <id> --entries-stdin --json`. To decline a credential request, pipe `{}` and include `--comment` explaining why. These commands reject stale requests. Credential values are never printed. Ask the user for decisions and access that the agent cannot supply; `wait_for_arcanist` requires Arcanist to intervene.
31
+
13
32
  ## Quick start
14
33
 
15
34
  ```bash
@@ -138,7 +157,7 @@ arcanist environments prepare --wait --json
138
157
  arcanist environments prepare owner/repo --wait --poll-interval 5000 --json
139
158
  ```
140
159
 
141
- Agents should follow `repository.nextAction` and `repository.command`. Request an Arcanist review only when `nextAction` is `review`. When `command` is `null`, do not invent an API call; surface `question` / `secretRequest` to a human. `--wait` waits through internal handoffs until setup is ready or there is a real action for the user or Arcanist.
160
+ Agents should follow `repository.nextAction` and `repository.command`. Request an Arcanist review only when `nextAction` is `review`. Use the returned answer or credential command for `question` / `secretRequest`; obtain missing decisions or credentials from the user. When `command` is `null`, surface the required human or Arcanist action. `--wait` waits through internal handoffs until setup is ready or there is a real action for the user or Arcanist.
142
161
 
143
162
  ### `arcanist environments status`
144
163
 
@@ -149,7 +168,7 @@ arcanist environments status owner/repo --json
149
168
  arcanist environments status owner/repo --wait --poll-interval 5000 --json
150
169
  ```
151
170
 
152
- Agents should follow `repository.nextAction` and `repository.command`. Request an Arcanist review only when `nextAction` is `review`. When `command` is `null`, do not invent an API call; surface `question` / `secretRequest` to a human. `--wait` waits through internal handoffs until setup is ready or there is a real action for the user or Arcanist.
171
+ Agents should follow `repository.nextAction` and `repository.command`. Request an Arcanist review only when `nextAction` is `review`. Use the returned answer or credential command for `question` / `secretRequest`; obtain missing decisions or credentials from the user. When `command` is `null`, surface the required human or Arcanist action. `--wait` waits through internal handoffs until setup is ready or there is a real action for the user or Arcanist.
153
172
 
154
173
  ### `arcanist environments retry`
155
174