argos-cli
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseArgos CLI
Argos CLI
Run for the exact flags of any command. This skill
covers only what can't: the token model, the output contract, and the
command map.
argos <command> --help--help运行可查看任意命令的具体参数。本指南仅涵盖未提及的内容:令牌模型、输出约定以及命令映射。
argos <command> --help--helpOutput contract (agents)
输出约定(面向Agent)
- Pass whenever you parse stdout; commands print human-readable text otherwise.
--json - Errors go to stderr as . Exit
Error: <message>= success,0= failure.1 - Never print token values.
- 当你解析标准输出时,请始终传递参数;否则命令会输出人类可读的文本。
--json - 错误信息会以的形式输出到stderr。退出码
Error: <message>表示成功,0表示失败。1 - 切勿打印令牌值。
Authentication
身份验证
A is a build number (e.g. ) or a full build URL. With a
number, add ; a URL already contains it. A
is not a build ref: it comes from a diff's and does not carry the
account, so every command needs (or
).
<buildReference>72652--project owner/project<changeId>change.idchange--project owner/projectARGOS_PROJECTTwo token types — pick by command:
| Commands | Token | Resolution order |
|---|---|---|
| Project token | |
| Personal access token (PAT) | |
| CI / project token | |
Project tokens read build data but cannot review, comment, or ignore
changes — those need a PAT. If no suitable token is available, ask the user. For
these actions, if no PAT exists, report the conclusion and evidence instead of
acting. is for interactive humans, not CI.
argos login<buildReference>72652--project owner/project<changeId>change.idchange--project owner/projectARGOS_PROJECT有两种令牌类型,需根据命令选择:
| 命令 | 令牌类型 | 优先级顺序 |
|---|---|---|
| 项目令牌 | |
| 个人访问令牌(PAT) | |
| CI/项目令牌 | |
项目令牌可读取构建数据,但无法进行审核、评论或忽略变更——这些操作需要PAT。如果没有合适的令牌,请询问用户。对于这些操作,如果不存在PAT,请报告结论和依据,而非执行操作。适用于交互式人工操作,不适用于CI环境。
argos loginCommands
命令
- Inspect — ·
build get <ref>build snapshots <ref> [--needs-review] [--metrics-period 24h|3d|7d|30d|90d] - Review — ·
review list <ref>·review create <ref> --event <approve|reject|comment> [--body <md>]review dismiss <ref> <reviewId> - Comment — ·
comment list <ref>·comment create <ref> --body <md> [--reply-to <id>] [--diff <id>] [--draft]·comment get|edit|delete|resolve|unresolve|subscribe|unsubscribe <ref> <id>comment react|unreact <ref> <id> <emoji> - Flakiness — ·
change ignore <changeId> --project owner/projectchange unignore <changeId> --project owner/project - Account — ·
analytics --account <slug>·create-project <name> --account <slug>whoami - CI — ·
upload <dir>·finalize·skipdeploy <dir> - Auth — ·
loginlogout
build snapshots --jsontest.metricsstabilityconsistencyflakinesschangeidignoredoccurrencesoccurrencesflakinesschange.idchange ignore- 检查 — ·
build get <ref>build snapshots <ref> [--needs-review] [--metrics-period 24h|3d|7d|30d|90d] - 审核 — ·
review list <ref>·review create <ref> --event <approve|reject|comment> [--body <md>]review dismiss <ref> <reviewId> - 评论 — ·
comment list <ref>·comment create <ref> --body <md> [--reply-to <id>] [--diff <id>] [--draft]·comment get|edit|delete|resolve|unresolve|subscribe|unsubscribe <ref> <id>comment react|unreact <ref> <id> <emoji> - 测试不稳定处理 — ·
change ignore <changeId> --project owner/projectchange unignore <changeId> --project owner/project - 账户 — ·
analytics --account <slug>·create-project <name> --account <slug>whoami - CI — ·
upload <dir>·finalize·skipdeploy <dir> - 身份验证 — ·
loginlogout
build snapshots --jsontest.metricsstabilityconsistencyflakinesschangeidignoredoccurrencesoccurrencesflakinesschange.idchange ignoreCommon flows
常见流程
Review a build (inspect with a project token, decide with a PAT):
bash
ARGOS_TOKEN=<project-token> argos build snapshots <ref> --needs-review --json
argos review create <ref> --token <pat> --event approve --json审核构建(使用项目令牌检查,使用PAT执行操作):
bash
ARGOS_TOKEN=<project-token> argos build snapshots <ref> --needs-review --json
argos review create <ref> --token <pat> --event approve --jsonregression: argos review create <ref> --token <pat> --event reject --body "..."
回归处理: argos review create <ref> --token <pat> --event reject --body "..."
Silence a flaky change (inspect with a project token, ignore with a PAT).
Ignored changes stop requiring review and are auto-approved on future builds:
```bash
ARGOS_TOKEN=<project-token> argos build snapshots <ref> --json # read each diff's change.id + occurrences
argos change ignore <changeId> --token <pat> --project owner/project
忽略不稳定的变更(使用项目令牌检查,使用PAT执行忽略操作)。被忽略的变更将不再需要审核,且在未来构建中会自动通过:
```bash
ARGOS_TOKEN=<project-token> argos build snapshots <ref> --json # 读取每个差异的change.id和occurrences
argos change ignore <changeId> --token <pat> --project owner/projectrevert: argos change unignore <changeId> --token <pat> --project owner/project
撤销忽略: argos change unignore <changeId> --token <pat> --project owner/project
Upload screenshots in CI:
```bash
argos upload ./screenshots --token $ARGOS_TOKENParallel builds:
bash
argos upload ./screenshots --parallel-nonce $ID --parallel-index $i --parallel-total $n
argos finalize --parallel-nonce $ID
在CI中上传截图:
```bash
argos upload ./screenshots --token $ARGOS_TOKEN并行构建:
bash
argos upload ./screenshots --parallel-nonce $ID --parallel-index $i --parallel-total $n
argos finalize --parallel-nonce $ID