crates/but/skill/README.md
Agent skill for working with the GitButler CLI (but command) in workspace mode.
Install this skill using the GitButler CLI:
but skill install # Prompts for scope and format
The command prompts you to choose local (repository) or global (home directory) scope first, then prompts you to select a skill format (Agent Skills / .agents/skills, Claude Code, OpenCode, Codex, GitHub Copilot, Cursor, or Windsurf) and installs to the appropriate location. When run outside a git repository, local scope is unavailable and the default install location is global (home directory), but you can still install to a custom location with --path using an absolute or ~ path.
Options:
--path <path> - Install to a custom path (outside a repository, relative paths require --global)--global - Install globally (in home directory) instead of current repository--detect - Auto-detect installation location from existing installation (useful for updates)
In non-interactive mode, use --path or --detect.Requirements:
curl -sSL https://gitbutler.com/install.sh | sh.agents/skills, Claude Code, OpenCode, Codex, GitHub Copilot, Cursor, or Windsurfbut setup (only for local installs)Updating:
To update the skill to the latest version, use the --detect flag to automatically detect and update your existing installation:
but skill install --detect
Alternatively, re-run the install command and select the same location:
but skill install
This will overwrite the existing skill files with the latest version.
The skill directory contains both distributable skill files and development documentation:
crates/but/skill/
├── SKILL.md ← Skill entry point (INSTALLED)
├── README.md ← This file - development docs (NOT installed)
├── RESEARCH.md ← Tier 4 testing research and strategy (NOT installed)
├── eval/ ← Tier 4 integration eval harness (NOT installed)
└── references/ ← Additional skill documentation (INSTALLED)
├── reference.md - Command reference
├── concepts.md - Deep concepts
└── examples.md - Workflow examples
What gets installed:
The but skill install command only copies the distributable files to the user's system:
SKILL.md - Main skill entry pointreferences/ - All reference documentation filesWhat stays in the repository: Development documentation remains in the source tree and is not installed:
README.md - This file (development and maintenance docs)RESEARCH.md - Testing strategy and learningseval/ - Tier 4 integration test harness and scenariosClaude automatically invokes this skill when:
Claude loads files on-demand:
Files in references/ directory are only loaded when explicitly referenced, keeping context lean while providing comprehensive documentation when needed.
The YAML description field contains all triggering information so Claude knows when to use this skill before loading the body.
SKILL.md is kept under 150 lines as a "table of contents" that points to detailed materials.
Separate files by domain (commands, concepts, examples) so Claude only loads relevant context.
Uses directive language ("do this") rather than passive ("this might happen").
but commandsKeep SKILL.md at or under 250 lines. Split content into reference files if approaching the limit.
Test that Claude:
but commands instead of gitFor automated integration testing against real disposable repositories, use the Tier 4 harness in eval/:
Node must satisfy the promptfoo engine range documented in eval/README.md (repo baseline: lts/jod).
cd crates/but/skill/eval
pnpm install --ignore-workspace
pnpm approve-builds --ignore-workspace
pnpm run eval
# Optional: run the same harness with Codex instead of Claude
pnpm run eval:codex