Agent skill
bk
Use when checking Buildkite CI/CD builds, investigating failures, viewing job logs, or answering questions about pipeline status.
Install this agent skill to your Project
npx add-skill https://github.com/majiayu000/claude-skill-registry/tree/main/skills/other/other/bk
SKILL.md
Buildkite CI/CD
Investigate Buildkite builds, diagnose failures, and answer questions about pipeline status.
Arguments
$ARGUMENTS
Constraints
- Never assume CLI subcommands or flags. If unsure, run
bk <command> --helpfirst. - The
bkCLI uses-pfor pipeline and-bfor branch/build-number. Always check--helpfor the specific command. - Use
--no-timestampswithbk job logfor cleaner output. - Use
-o jsonwhen you need structured data for analysis.
Instructions
1. Parse Input
Determine what the user is asking about:
- Build URL (e.g.,
https://buildkite.com/org/pipeline/builds/123) → extract org, pipeline slug, build number - Build number → use with current repo's pipeline
- "latest" or no number → use
bk build viewwithout a number (resolves to current branch) - General question → use
bk build listorbk job listwith appropriate filters
2. Identify Pipeline
If not specified, infer from the current git repo. The bk CLI auto-detects pipeline when inside a repo.
If pipeline is ambiguous or bk can't detect it, use -p <pipeline-slug>.
3. Investigate
For build failures:
bk build view <number> -o json— get build state and job list- Find failed jobs (state:
failed, non-zeroexit_status) bk job log <job-id> -p <pipeline> -b <build-number> --no-timestamps— get failure logs- Read from the end of logs — errors are usually at the bottom
- For large logs, focus on lines near
exit_status,error,failed, orError
For general status:
bk build list -p <pipeline>— recent buildsbk build view— latest build on current branchbk job list -p <pipeline> --state failed— recent failures
4. Diagnose
When analyzing failures:
- Exit status codes:
-1= agent lost,255= forced agent shutdown,1= command failure,17= docker-compose plugin failure - Docker build failures: Look for
failed to solve:messages - Plugin failures: Look for
plugin <name> command hook exited with status - Infrastructure: Look for agent timeouts, OOM, disk space issues
- Test failures: Look for test framework output (go test, bats, jest, etc.)
5. Report
Provide a concise summary:
- Which step(s) failed
- Root cause (quote the key error lines)
- Suggested fix if apparent
Examples
/bk 91 → investigate build 91
/bk https://buildkite.com/gusto/my-pipe/builds/42 → investigate from URL
/bk latest → check latest build on current branch
/bk why did this fail → latest build, find failures
/bk list failed builds → recent failures for current pipeline
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
Didn't find tool you were looking for?