Skip to content

Add wt setup command#26

Merged
bkildow merged 1 commit into
mainfrom
feat/wt-setup
May 1, 2026
Merged

Add wt setup command#26
bkildow merged 1 commit into
mainfrom
feat/wt-setup

Conversation

@bkildow
Copy link
Copy Markdown
Owner

@bkildow bkildow commented May 1, 2026

Summary

  • New wt setup [name] command runs setup: and parallel_setup: hooks from .worktree.yml against an existing worktree
  • Primary use case: bootstrap a worktree created with wt add --skip-setup; also useful for re-running hooks after editing .worktree.yml
  • Supports --background / --foreground, the dot-alias (wt setup .), --dry-run, and refuses to double-launch when a setup is already running for the target worktree

Test plan

  • make dev (fmt + golangci-lint + full unit/e2e suite + build) is green
  • New e2e test e2e/testdata/setup.txtar covers: skipped→complete state transition, dot-alias resolution from $PWD, nonexistent-name error, --dry-run skips hook execution, "no setup hooks configured" info path, and --help text
  • Manual: wt add foo --skip-setup then wt setup foo runs hooks and updates .wt-setup.json to status=complete

Runs the setup and parallel_setup hooks from .worktree.yml against an
existing worktree. Primary use case: bootstrapping a worktree created
with `wt add --skip-setup`. Supports --background/--foreground, the dot
alias for the current worktree, dry-run, and refuses to run when a
setup is already in progress.
@bkildow bkildow merged commit 7c85310 into main May 1, 2026
@bkildow bkildow deleted the feat/wt-setup branch May 1, 2026 12:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant