cw-orient
Use at the start of any Codewhale work session, or when unsure whether the canonical checkout is on current `main` and what is dirty in it: establish live repo truth before reading a plan or editing a file.
- License 许可
- MIT
- 最近更新
- 2026-11-15
- Stars
- ★ 4.1w
- Forks
- 3.6k
01 前言 Front Matter
- name
- cw-orient
- description
- Use at the start of any Codewhale work session, or when unsure whether the canonical checkout is on current `main` and what is dirty in it: establish live repo truth before reading a plan or editing a file.
03 SKILL.md 正文
cw-orient
Open every session on live truth, not on a handoff note, a directory name, or
what was true last time. Several agents share this one checkout on main; the
cheapest bug to avoid is committing a live writer's half-written edit.
This is stage 1 of the loop: orient → cw-slice → cw-gates → cw-dogfood → cw-land → cw-handoff.
When to use
- Starting a session, resuming one, or taking over from another agent.
- A handoff, issue, or plan tells you the state of the repo — verify before trusting it.
- You are about to edit and are not certain what is dirty or who is writing.
Workflow
-
Locate yourself. Checkout, branch, dirt, and how far you are from the remote:
git rev-parse --show-toplevel && git branch --show-current git status --short --branch git log --oneline --decorate -10Agent work happens on
main. A detached HEAD or another branch here is a state to reconcile (preserve dirt and stranded commits, compare withorigin/main, return tomain) before editing; seeAGENTS.md§ Working rules. -
Look for stranded work, not lanes.
git worktree listand recent branches tell you what may hold unlanded commits. Inventory them; do not start work in someone else's. Create your own short-lived worktree fromorigin/mainonly after the inventory.git worktree list git branch --sort=-committerdate --format='%(committerdate:short) %(refname:short)' | head -20 -
Dirt in this checkout is yours (
AGENTS.md, founder 2026-10-22).git status --porcelain git diff --statCheck mtimes: a file changed in the last 15 minutes, or one a live session is editing, is mid-edit — ask that writer to commit, and commit the rest yourself in coherent verified groups (cw-land). Never stash,
checkout --, reset or clean it. -
Fix which guidance applies. The nearest scoped
AGENTS.mdwins over the root one, and it is where the per-area rules actually live:find . -name AGENTS.md -not -path './tmp/*' -not -path '*/node_modules/*' -not -path './target/*'Today: root
AGENTS.md,crates/tui/AGENTS.md,crates/localization/locales/AGENTS.md,web/AGENTS.md. Read the one that owns the files you are about to touch. -
Establish version truth from source, not memory.
grep -m1 '^version' Cargo.toml ./scripts/release/check-versions.shcheck-versions.shis the drift gate across the workspace version, npm,Cargo.lock, the changelog, and the README. If it disagrees with what you were told, believe the script. -
Only if the task is about the community queue — issues, PRs, harvesting, credit — pull the live queue with the
gh-*skills in this directory rather than assuming from memory. When the task is local-only, stay offline and record the missing external receipt instead.
Red flags / don't
- Don't infer the current state from a directory name, a stale handoff, or a
.mdfile's confident prose. All three have been wrong here. - Don't treat a plan document as current state. Plans describe intent;
gitdescribes reality. - Don't clean, stash, reset, or
git checkout --dirt in the checkout; read it, prove it, and commit it, or hand it to the live writer. - Don't use a new worktree to escape dirt or a conflict; inherited work is still yours.
- Don't skip step 4 because the root
AGENTS.md"probably covers it". The scoped files carry the rules that actually get violated. - Don't fetch, browse, or hit GitHub when the task was scoped local-only.
Output
Open with a short status block. Skip fields that are empty or normal — a
clean tree on main with no stranded work is one line, not five:
- checkout path, branch (or detached HEAD), base commit;
- dirty files and whether a live writer owns them;
- stranded branches or checkouts holding unlanded commits;
- workspace version and whether
check-versions.shagrees; - which
AGENTS.mdfiles govern this change.
04 同仓库更多 Skills
editing-cordis-compositions
Use when creating, changing, or validating an agent preset or other Cordis composition for this harness, including deciding host versus preset placement and checking that an authored preset mounts.
cordis-plugin-development
Use when designing, reviewing, adding, enabling, disabling, installing, configuring, or debugging a plugin, bundle, feature, page, panel, tool, or MCP connection in the current Harness profile, including a shipped plugin that is disabled by default, and for any visual object, decoration, or widget request that names no other destination, which means an installed UI plugin rendered in the Harness Web UI.
cordis-composition-reference
Use when writing or reading a Cordis bundle patch or agent preset for this harness and you need the Loader YAML dialect (insert, override by id, group, disabled, isolate, !!js) or the list of installable Harness plugin packages and what each provides.
agent-experience
Use when writing or changing a model-facing tool definition (name, description, parameter schema, or its system-prompt section), and when designing skills, context loading, or multi-step workflows, to make information discoverable and use context efficiently.
GitHub PR 与议题队列审查
gh-find-prs
以只读方式梳理开放的 Codewhale PR 和议题队列:获取每一项,对照当前代码进行核查,并生成一份包含引用证据和应致谢对象的覆盖度与处置矩阵。
GitHub 议题创建
gh-file-issue
用于提交新的 Codewhale GitHub 议题:将 bug 或想法转化为结构良好、可执行的议题,包含复现步骤、验收标准、标签和里程碑。