manage-task-workspaces

manage-task-workspaces is a skill for Codex from cyuanxv/agent-cockpit. It costs 67 tokens per session (751 once invoked), scanned A, original, MIT.

A workflow for giving coding tasks their own isolated Git worktrees, which are separate working directories connected to the same repository history. It covers setup, checks, commits, handoff, and recovery.

In plain words
What is it for?
Use it to create task workspaces, launch work in them, prepare selected files for commits, preview finishing actions, and handle failed or partially completed tasks.
Why use it?
It keeps changes from parallel tasks or agents separate and makes it safer to review, commit, finish, or recover work.

Skill for Codex

Written for Codex: agents/openai.yaml present.

Good fit Use it to create task workspaces, launch work in them, prepare selected files for commits, preview finishing actions, and handle failed or partially completed tasks.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/cyuanxv/agent-cockpit/manage-task-workspaces
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add cyuanxv/agent-cockpit --skill manage-task-workspaces
Clone the repo
git clone --depth 1 https://github.com/cyuanxv/agent-cockpit

Made for: Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for manage-task-workspaces

README.md
[![agentmods](https://agentmods.dev/badge/skills/cyuanxv/agent-cockpit/manage-task-workspaces.svg)](https://agentmods.dev/skills/cyuanxv/agent-cockpit/manage-task-workspaces)
Your own site
<a href="https://agentmods.dev/skills/cyuanxv/agent-cockpit/manage-task-workspaces"><img src="https://agentmods.dev/badge/skills/cyuanxv/agent-cockpit/manage-task-workspaces.svg" alt="Measured on agentmods" height="20"></a>
Per session 67 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 751 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00067 $0.00751
Opus 5 $0.00034 $0.00376
Sonnet 5 $0.00013 $0.00150
Haiku 4.5 $0.00007 $0.00075

Measured 8d ago against content hash 4fa9a8c6c5e7, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade A, and why

manage-task-workspaces scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 8d ago.

The scan reads SKILL.md. This mod also ships 2 executable files (scripts/task_workspace.py, tests/test_task_workspace.py), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/manage-task-workspaces/SKILL.md · 85 lines

What it actually says

管理任务 Worktree

适用规则

  • 只读盘点不创建 Worktree;第一次写入前创建。
  • 使用安装后的 cockpit 命令,不手工拼接多仓库 Worktree。
  • 每个仓库只提交明确列出的相对路径。
  • finish、外部推送、PR、合并和 cleanup 都保留独立门禁。
  • 状态真相在规范仓根的 .cockpit-runs/task-workspaces/<task-id>/state.json

遇到失败、部分推送、PR 已合并但状态滞后或清理拒绝时,读取 references/recovery.md

标准流程

  1. 检查环境和仓库配置:

    cockpit --root <workspace-root> doctor
    cockpit --root <workspace-root> repos
    
  2. 创建任务空间;根仓自动加入,其它仓库显式指定:

    cockpit --root <workspace-root> start <task-id> --repo <repo-key>
    

    mount_path 必须已经被根仓 .gitignore 忽略。不要把原 dirty 目录的 未提交文件搬进任务空间。

  3. 在输出的 workspace 内工作。需要切换客户端时,只打印启动命令:

    cockpit --root <workspace-root> launch <task-id> --runtime <runtime-key>
    
  4. 每个仓库单独检查或提交:

    cockpit --root <workspace-root> prepare <task-id> \
      --repo <repo-key> \
      --path <relative-path> \
      --message "<commit message>"
    

    提交语言和格式由 .cockpit/config.jsoncommit_message_pattern 决定;未配置时不限制语言。

  5. 收尾前先展示无副作用计划:

    cockpit --root <workspace-root> finish <task-id> --dry-run
    
  6. 只有用户明确授权外部集成后,才传配置中的确认短语:

    cockpit --root <workspace-root> finish <task-id> --confirm <phrase>
    

    默认短语是 integrate。必须逐仓遵守 manuallocal_onlypull_requestdirect_main 策略,不能临时降级安全门禁。

  7. 清理是单独动作,先预览再确认:

    cockpit --root <workspace-root> cleanup <task-id> --dry-run
    cockpit --root <workspace-root> cleanup <task-id> --confirm cleanup
    

    清理只移除符合条件的干净 Worktree,保留任务分支和审计状态;不提供 --force

报告内容

向用户报告任务 workspace、任务分支、各仓库阶段、实际验证、未验证边界和 下一步。没有后续动作时明确写“任务完结”。

Files

What ships with it

8 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 8d ago First seen · 85 lines · 67 tokens per session scan A 4fa9a8c6c5e7

Subscribe to this mod's changes

manage-task-workspaces is a skill published in the GitHub repository cyuanxv/agent-cockpit (2 stars, last pushed 1mo ago), licensed MIT. It adds 67 tokens to every session and 751 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories