opencode-kanban-cli

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

opencode-kanban-cli

opencode-kanban-cli

Use this skill to run
opencode-kanban
commands correctly and avoid common argument mistakes.
使用本技能可以正确运行
opencode-kanban
命令,避免常见的参数错误。

When to use

使用场景

  • The user asks how to use
    opencode-kanban
    from terminal scripts.
  • The user hits CLI parsing errors (
    --project
    ,
    --id
    , selector conflicts).
  • The user needs ready-to-copy command examples for task/category workflows.
  • 用户询问如何从终端脚本中使用
    opencode-kanban
  • 用户遇到CLI解析错误(
    --project
    --id
    、选择器冲突)。
  • 用户需要可直接复制的任务/分类工作流命令示例。

Instructions

使用说明

  1. Start by applying these global CLI rules:
    • For all non-TUI commands,
      --project <PROJECT>
      is required.
    • --project
      and
      --json
      are global and can appear before or after subcommands.
    • The project must already exist, otherwise the CLI returns
      PROJECT_NOT_FOUND
      .
  2. Use command groups exactly as follows:
    • task list [--repo <REPO>] [--category-id <UUID> | --category-slug <SLUG>] [--archived]
    • task create --title <TEXT> --branch <BRANCH> --repo <REPO> [--category-id <UUID> | --category-slug <SLUG>]
    • task move --id <TASK_ID_OR_PREFIX> (--category-id <UUID> | --category-slug <SLUG>)
    • task show --id <TASK_ID_OR_PREFIX>
    • task archive --id <TASK_ID_OR_PREFIX>
    • category list
    • category create --name <TEXT> [--slug <SLUG>]
    • category update --id <CATEGORY_ID> [--name <TEXT>] [--slug <SLUG>] [--position <N>]
    • category delete --id <CATEGORY_ID>
  3. Follow selector semantics precisely:
    • Category destination selectors are mutually exclusive: use exactly one of
      --category-id
      or
      --category-slug
      when required.
    • task move
      requires one category selector.
    • task show
      ,
      task move
      , and
      task archive
      accept full UUID or unique short ID prefix from table output (for example
      e11ad40a
      ).
    • --repo
      accepts either a repo name or the repo path (matching registered repos).
  4. Be explicit about
    task create
    behavior:
    • It performs the same creation workflow as TUI: validates branch, resolves base branch, fetches/checks base, creates git worktree, creates tmux session, then persists task runtime metadata.
    • If any step fails, it rolls back created artifacts (task row, tmux session, worktree) when possible.
  5. Prefer these validated examples:
bash
undefined
  1. 首先遵循以下全局CLI规则:
    • 对于所有非TUI命令,必须指定
      --project <PROJECT>
    • --project
      --json
      是全局参数,可在子命令之前或之后出现。
    • 项目必须已存在,否则CLI会返回
      PROJECT_NOT_FOUND
      错误。
  2. 严格按照以下命令组使用:
    • task list [--repo <REPO>] [--category-id <UUID> | --category-slug <SLUG>] [--archived]
    • task create --title <TEXT> --branch <BRANCH> --repo <REPO> [--category-id <UUID> | --category-slug <SLUG>]
    • task move --id <TASK_ID_OR_PREFIX> (--category-id <UUID> | --category-slug <SLUG>)
    • task show --id <TASK_ID_OR_PREFIX>
    • task archive --id <TASK_ID_OR_PREFIX>
    • category list
    • category create --name <TEXT> [--slug <SLUG>]
    • category update --id <CATEGORY_ID> [--name <TEXT>] [--slug <SLUG>] [--position <N>]
    • category delete --id <CATEGORY_ID>
  3. 精准遵循选择器语义:
    • 分类目标选择器互斥:需要使用时,必须且只能使用
      --category-id
      --category-slug
      其中之一。
    • task move
      需要一个分类选择器。
    • task show
      task move
      task archive
      接受完整UUID或表格输出中的唯一短ID前缀(例如
      e11ad40a
      )。
    • --repo
      接受仓库名称或仓库路径(与已注册的仓库匹配)。
  4. 明确说明
    task create
    的行为:
    • 它执行与TUI相同的创建工作流:验证分支、解析基础分支、获取/检查基础分支、创建git worktree、创建tmux会话,然后持久化任务运行时元数据。
    • 如果任何步骤失败,会尽可能回滚已创建的工件(任务行、tmux会话、worktree)。
  5. 优先使用以下经过验证的示例:
bash
undefined

Global flags can be placed after subcommands

全局参数可放在子命令之后

opencode-kanban task list --project test --json
opencode-kanban task list --project test --json

Create task with full workflow (worktree + tmux session + metadata)

创建包含完整工作流的任务(worktree + tmux会话 + 元数据)

opencode-kanban task create --project test --title "Refactor parser" --branch feature/refactor-parser --repo /path/to/repo --category-slug todo
opencode-kanban task create --project test --title "Refactor parser" --branch feature/refactor-parser --repo /path/to/repo --category-slug todo

Move using short task id prefix from table output

使用表格输出中的短任务ID前缀移动任务

opencode-kanban task move --project test --id e11ad40a --category-slug in-progress
opencode-kanban task move --project test --id e11ad40a --category-slug in-progress

Show categories as pretty table

以美观表格形式显示分类

opencode-kanban category list --project test

6. If user reports an error, map it quickly:
   - `PROJECT_REQUIRED` -> missing `--project`
   - `PROJECT_NOT_FOUND` -> project DB does not exist yet
   - `UNIQUE_CONSTRAINT` on create -> duplicate `(repo, branch)`
   - `TASK_ID_AMBIGUOUS` -> provide longer task id prefix
   - `CATEGORY_SELECTOR_CONFLICT` -> both category selectors were provided
opencode-kanban category list --project test

6. 如果用户报告错误,快速对应:
   - `PROJECT_REQUIRED` -> 缺少`--project`参数
   - `PROJECT_NOT_FOUND` -> 项目数据库尚未存在
   - 创建时出现`UNIQUE_CONSTRAINT` -> `(repo, branch)`重复
   - `TASK_ID_AMBIGUOUS` -> 提供更长的任务ID前缀
   - `CATEGORY_SELECTOR_CONFLICT` -> 同时提供了两个分类选择器