agentleFS
yuelenghanyuelenghan/orbit/skills/bitbucket/SKILL.md

bitbucket

Skill0 starsChanged 5 months agoMITView on GitHub

Use when the user needs Bitbucket Data Center repository, branch, pull request, comment, merge, or build-trigger operations.

The file

Show its rules and text

We split this skill into the rules it gives an agent

16 rules. About 0 are common, 3 are distinctive, and 13 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈3

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 13

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Use this skill to operate Bitbucket Data Center repositories, branches, and pull requests through the packaged launcher and local CLI …

    line 15
  2. Very specific:

    Always run the packaged launcher through ${BITBUCKET_SKILL_DIR} so it works from the user's current working directory:

    line 19
  3. Very specific:

    Do not execute ${BITBUCKET_SKILL_DIR}/bin/bitbucket or ${BITBUCKET_SKILL_DIR}\bin\bitbucket.cmd literally when the host has not resolved …

    line 25
  4. Very specific:

    When the host leaves the placeholder unresolved, check the current workspace install first, such as .claude/skills/bitbucket/bin/bitbucket …

    line 27
  5. Very specific:

    Do not call node dist/cli.js directly.

    line 28
  6. Very specific:

    Do not start with version, doctor, or --help when the user already asked for a concrete Bitbucket read or write task, unless the launcher …

    line 29
  7. Very specific:

    When exact command syntax is unclear, use the packaged launcher with <group> --help or <group> <action> --help before guessing flags.

    line 30
  8. Distinctive:

    Do not call Bitbucket REST API directly from the skill layer.

    line 37
  9. Distinctive:

    Prefer stable, structured CLI output that downstream agents can parse reliably.

    line 42
  10. Very specific:

    Use these directly without reading supporting files.

    line 52
  11. Very specific:

    Only fall back to BIN build jenkins-trigger ...

    line 70
  12. Very specific:

    Run bitbucket config get when configuration state is unknown or before the first provider-scoped task in a new session.

    line 113
  13. Very specific:

    Read references/commands.md for command families and packaged launcher forms.

    line 117
  14. Very specific:

    Read references/usage.md for execution policy, aggregation rules, and read/write behavior.

    line 118
  15. Very specific:

    Follow references/usage.md finding classification and routing rules before submitting PR review feedback.

    line 119
  16. Very specific:

    Read examples/common-workflows.md for end-to-end examples.

    line 120

≈ “Common” is an estimate: at least 1 in 5 of the 213,897 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Bitbucket Skill

This skill is one implementation of the repo capability in the Orbit shared provider framework. Core repository, branch, and pull request operations live here; repo required-reviewers, jira pr-issues, jira issue-commits, and similar bridge flows are optional Bitbucket-specific enhancements layered on top.

Use this skill to operate Bitbucket Data Center repositories, branches, and pull requests through the packaged launcher and local CLI runtime.

Runtime and execution

Always run the packaged launcher through ${BITBUCKET_SKILL_DIR} so it works from the user's current working directory:

  • macOS/Linux: ${BITBUCKET_SKILL_DIR}/bin/bitbucket
  • Windows: ${BITBUCKET_SKILL_DIR}\bin\bitbucket.cmd

${BITBUCKET_SKILL_DIR} is a documentation placeholder, not a guaranteed shell environment variable. Do not execute ${BITBUCKET_SKILL_DIR}/bin/bitbucket or ${BITBUCKET_SKILL_DIR}\bin\bitbucket.cmd literally when the host has not resolved that placeholder. Resolve BIN to a real launcher path once before the first CLI call. When the host leaves the placeholder unresolved, check the current workspace install first, such as .claude/skills/bitbucket/bin/bitbucket or .Codex/skills/bitbucket/bin/bitbucket, then fall back to the host-provided installed skill directory when available. Do not call node dist/cli.js directly. Do not start with version, doctor, or --help when the user already asked for a concrete Bitbucket read or write task, unless the launcher itself is failing. When exact command syntax is unclear, use the packaged launcher with <group> --help or <group> <action> --help before guessing flags. The launcher first reuses a compatible system Node runtime when available (currently Node >= 20), and only downloads the required runtime into the local cache when the machine does not already have one.

Scope and boundaries

  • Bitbucket Data Center only (not Bitbucket Cloud).
  • CLI-mediated operations only.
  • Do not call Bitbucket REST API directly from the skill layer.
  • The CLI may use explicitly allowlisted plugin endpoints when the project scope permits them, including the Jenkins branch trigger endpoint for build jenkins-trigger.

Provider-specific caveats

  • Prefer stable, structured CLI output that downstream agents can parse reliably.
  • Distinguish read actions and write actions explicitly.
  • For write failures, return explicit and actionable failure details; do not swallow errors.

Review behavior

  • During code review, if no high-confidence, actionable, non-trivial issues are found, return a clean result instead of proposing or submitting comments, and use pr approve when the task is to submit the review result.

Quick reference — common operations

Use these directly without reading supporting files. BIN = the resolved launcher path for this session, not the literal ${BITBUCKET_SKILL_DIR} placeholder token.

TaskCommand
Trigger build (simplified)BIN build trigger --repo <slug> --branch <name> [--project <KEY>]
Trigger build (explicit)BIN build jenkins-trigger --project <KEY> --repo <slug> --branch refs/heads/<name>
List repos in a projectBIN repo list --project <KEY>
Search repos by nameBIN repo search --name <name>
List open PRs (project)BIN pr list --project <KEY> --state OPEN --draft false
List merged PRs (date)BIN pr list --project <KEY> --state MERGED --after YYYY-MM-DD
Get single PRBIN pr get --project <KEY> --repo <slug> --id <ID>
Create branchBIN branch create --project <KEY> --repo <slug> --name <branch> --start-point <ref>
Read file contentBIN repo content --project <KEY> --repo <slug> --path <path> [--at <ref>]

Notes on build trigger:

  • --branch accepts short names like dev (auto-prefixed to refs/heads/dev) or full refs.
  • --project is optional; when omitted, auto-resolved from repo slug via search. If multiple repos share the same slug across projects, specify --project explicitly.
  • For requests to trigger a specific repository branch build, default to BIN build trigger --repo <slug> --branch <name> and do not run repo search just to discover the project key.
  • Only fall back to BIN build jenkins-trigger ... when the user already provided --project, build trigger reports that the same slug exists in multiple projects, or the user explicitly asks for full refs or explicit control.
  • Protected branches (main/master/prod/production) require --confirm-production true.

Capability Domain

Domain:

  • repo

Provides:

  • repo.config.get
  • repo.config.set
  • repo.repo.list
  • repo.repo.search
  • repo.repo.get
  • repo.repo.content
  • repo.repo.default-branch.get
  • repo.branch.list
  • repo.branch.create
  • repo.pr.list
  • repo.pr.get
  • repo.pr.changes
  • repo.pr.diff
  • repo.pr.activities
  • repo.pr.create
  • repo.pr.update
  • repo.pr.comment
  • repo.pr.review-comment
  • repo.pr.approve
  • repo.commit.list
  • repo.commit.get
  • repo.commit.changes
  • repo.commit.pull-requests
  • repo.repo.required-reviewers
  • repo.pr.linked-work-items
  • repo.issue.linked-commits-via-repo
  • project-scoped pull request aggregation
  • provider-specific workflow helpers

Config check:

  • bitbucket config get

Config check

Run bitbucket config get when configuration state is unknown or before the first provider-scoped task in a new session.

Supporting files

  • Read references/commands.md for command families and packaged launcher forms.
  • Read references/usage.md for execution policy, aggregation rules, and read/write behavior.
  • Follow references/usage.md finding classification and routing rules before submitting PR review feedback.
  • Read examples/common-workflows.md for end-to-end examples.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.