wt-switch-create
Create a new worktrunk worktree (optionally in another repo) and switch this session's working directory into it. Use when launching a session that should work in its own worktree (e.g. `/wt-switch-create my-branch -- <task>`, or `/wt-switch-create my-branch ~/workspace/other-repo -- <task>`), or mid-session to move work into a fresh branch.
What this skill does
Arguments: `$ARGUMENTS`. Grammar: `<branch> [<repo>] [-- <task>]`.
- **branch** — required first token; the branch name for the new worktree.
- **repo** — optional path; create the worktree in this repo instead of the
session's current one.
- **task** — optional; what to do inside the new worktree. No task means enter
the worktree and wait.
Without a `--`: a path-shaped second token (absolute, `~`-relative, `./`- or
`../`-relative, or an existing directory) is the repo, and the task starts
after it. Otherwise the task starts at the second token.
```
/wt-switch-create my-feature -- fix the parser bug
/wt-switch-create my-feature ~/workspace/other-repo -- fix the parser bug
/wt-switch-create my-feature
```
## What to do
1. **First action — before reading any files or running any commands:**
- If a repo was given, `cd` into it first with a `Bash` call (the working
directory persists for the rest of the session). `EnterWorktree` has no
repo parameter — it creates the worktree wherever the session is rooted.
- Then call `EnterWorktree({name: "<branch-name>"})`. This re-roots the
session into the new worktree. If a repo was given, confirm the new
worktree landed under it; if not, the `cd` didn't take — report it and
stop.
- It works because this plugin maps `WorktreeCreate` →
`wt switch --create <name> --no-cd --format=json`, so the new worktree
lands in worktrunk's normal sibling layout (`<repo>.<branch>/`), not under
`.claude/worktrees/`.
- `wt switch --create` is idempotent: if the branch already exists, this
just re-enters its worktree.
- If you are *already* inside an `EnterWorktree`-created worktree (e.g. the
background harness isolated this session), **skip `EnterWorktree`** — it
refuses to nest. Reuse the existing worktree and continue. But if a repo
was given and that worktree belongs to a different repo, you can't honor
it — say so and stop rather than running the task in the wrong repo.
- If `EnterWorktree` fails (not a git repo, invalid branch name, etc.),
report the error and stop — do not fall back to working in the original
directory, since that defeats the purpose.
2. After the cwd switch succeeds, do the task in the new worktree. If there was
no task text, confirm the worktree is ready and wait for the next
instruction.
## Cleanup
Don't remove the worktree yourself. `ExitWorktree({action: "remove"})` (if the
user asks to leave) or the session-exit prompt routes through this plugin's
`WorktreeRemove` hook → `wt remove --foreground`. A worktree with uncommitted
changes won't be auto-removed without confirmation — that's intended. A branch
with committed-but-unmerged work is retained (with a `wt remove -D <branch>`
hint) instead of being silently force-deleted.
## Scope
This command authorizes creating/entering ONE worktree — in the named repo, if
one was given — and doing the requested task. Commits, pushes, and merges still
each require explicit user permission.
Related in Productivity
gitea-workflow
IncludedOrchestrate agile development workflows for Gitea repositories using the tea CLI. Use when working with Gitea-hosted repos and asking to 'run the workflow', 'continue working', 'what's next', 'complete the task cycle', 'start my day', 'end the sprint', 'implement the next task', or wanting guided step-by-step development assistance. Keywords: workflow, orchestrate, agile, task cycle, sprint, daily, implement, review, PR, standup, retrospective, gitea, tea.
microsoft-graph-gateway
IncludedRoute Microsoft Graph work in this workspace. Use when users want to read or write Outlook mail, calendar events, contacts, OneDrive or SharePoint files, Teams, Planner, To Do, users, groups, directory data, or arbitrary Microsoft Graph endpoints from VS Code. Prefer WorkIQ for common read scenarios. Use Microsoft Graph for write actions and gap-read scenarios that need exact Graph properties, filters, permissions, or endpoints.
copilotkit
IncludedUse when building with CopilotKit — setup, development, integrations, debugging, upgrading, or contributing. Routes to the appropriate specialized skill based on the task.
wordly-wisdom
IncludedProvides calibrated decision analysis using Charlie Munger-style multiple mental models, inversion, incentive mapping, circle-of-competence checks, misjudgment audits, second-order effects, and forecast updates. Use when the user asks for an oracle take, a hard call, a decision memo, a premortem, an outside view, a red-team, a sanity-check, what am I missing, think this through, or wants a strategy, hire, investment, plan, product, partnership, or major life choice analysed. Avoid for simple factual lookups or time-sensitive legal, medical, or market questions without fresh evidence.
swain-session
IncludedSession management and project status dashboard. Owns the full session lifecycle (start/work/close/resume), focus lane, bookmarks, worktree detection, and tab naming. Also serves as the project status dashboard — shows active epics, progress, actionable next steps, blocked items, tasks, GitHub issues, and recommendations. Worktree creation is deferred to swain-do task dispatch (SPEC-195). Triggers on: 'session', 'status', 'what's next', 'dashboard', 'overview', 'where are we', 'what should I work on', 'show me priorities', 'bookmark', 'focus on', 'session info'.
gandi
IncludedComprehensive Gandi domain registrar integration for domain and DNS management. Register and manage domains, create/update/delete DNS records (A, AAAA, CNAME, MX, TXT, SRV, and more), configure email forwarding and aliases, check SSL certificate status, create DNS snapshots for safe rollback, bulk update zone files, and monitor domain expiration. Supports multi-domain management, zone file import/export, and automated DNS backups. Includes both read-only and destructive operations with safety controls.