Agent skill
pr-bb
Fetches review comments for a given Bitbucket pull request. Use when reviewing or analyzing PR feedback from Bitbucket.
Install this agent skill to your Project
npx add-skill https://github.com/geggo98/dotfiles/tree/main/modules/ai/_files/skills/bitbucket-pr
SKILL.md
Bitbucket Pull Request Skill
1. Purpose
Use this skill to fetch and review comments from Bitbucket pull requests. It retrieves all comments from a PR or fetches a specific comment by ID for detailed analysis.
2. Usage Scenarios
Run before:
- Reviewing PR comments to address feedback.
- Analyzing discussion patterns in a pull request.
- Extracting specific comment details for documentation.
- Understanding inline vs. general comments on a PR.
3. Helper Scripts
| Script | Purpose | Arguments |
|---|---|---|
scripts/bitbucket_pr_comments.sh |
Fetch Bitbucket PR comments | list or get |
Arguments
- Required: PR ID (pull request identifier)
- For
getmode: Comment ID (specific comment identifier) - Modes:
list- Get all comments for a PR (default)get- Get one specific comment by ID
4. Examples
List All Comments
bitbucket_pr_comments.sh list 12345
Returns all comments with ID, content, and inline status for PR #12345.
Get Specific Comment
bitbucket_pr_comments.sh get 12345 67890
Returns detailed content for comment ID 67890 on PR #12345.
Pipe to jq for Custom Filtering
bitbucket_pr_comments.sh list 12345 | jq 'map(select(.inline == true))'
Filter to show only inline comments.
5. Output Format
List Mode (JSON array)
[
{
"id": "67890",
"content": "Please review this change.",
"inline": false
},
{
"id": "67891",
"content": "Consider using async/await here.",
"inline": true
}
]
Get Mode (Raw content)
Returns the raw markdown content of the specified comment.
6. Exit Codes
| Code | Meaning |
|---|---|
| 0 | Success |
| 1 | Invalid arguments |
| 2 | Bitbucket CLI not found |
| 3 | API or network failure |
| 4 | PR or comment not found |
7. Environment Variables
| Variable | Description |
|---|---|
BITBUCKET_CLI |
Path to bb CLI (default: bb) |
JQ_PATH |
Path to jq (default: jq) |
8. Troubleshooting
| Problem | Possible Cause | Fix |
|---|---|---|
bb: command not found |
Bitbucket CLI not installed | Install Atlassian CLI |
jq: command not found |
jq not installed | Install via brew/apt |
Error: Invalid PR ID |
Non-numeric PR ID provided | Use numeric PR ID only |
Error: Invalid comment ID |
Non-numeric comment ID for get mode | Use numeric comment ID only |
| Empty output | No comments on PR | Verify PR has comments |
9. Prerequisites
- Bitbucket CLI (
bb) installed and authenticated - jq for JSON parsing
- Access to the target Bitbucket repository
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
eval-notebook
Execute .ipynb notebooks (Python, Kotlin, or any Jupyter kernel) without overwriting; return LLM-friendly JSON with outputs and errors. Use when you need to run or validate a Jupyter notebook.
nix-shell
Search Nix packages and run commands with packages from nixpkgs that are not installed locally. Use when you need a package not available locally or want to search nixpkgs.
tmux
Remote control tmux sessions for interactive CLIs (python, gdb, etc.) by sending keystrokes and scraping pane output.
slidev
Create and present web-based slidedecks for developers using Slidev with Markdown, Vue components, code highlighting, animations, and interactive features. Use when building technical presentations, conference talks, code walkthroughs, teaching materials, or developer decks. Also trigger when the user mentions Slidev, sli.dev, slide decks with code, or wants to create developer-facing presentations.
diagram-render
Render PlantUML (@startuml…@enduml) and Mermaid fenced blocks to a self-contained HTML preview; if rendering fails, the error text must be embedded in the output image. Use when the user asks to render, preview, or export diagrams.
adr-writing
Use when documenting significant architectural decisions. Creates focused ADRs explaining context, decision, and alternatives. Prevents vague documentation and implementation detail bloat. Triggers: 'create ADR', 'document decision', making technology/framework/persistence/auth choices, cross-cutting concerns.
Didn't find tool you were looking for?