{"id":28899265,"url":"https://github.com/gildas/bitbucket-cli","last_synced_at":"2026-02-14T14:07:06.574Z","repository":{"id":212585702,"uuid":"731851424","full_name":"gildas/bitbucket-cli","owner":"gildas","description":"Bitbucket CLI","archived":false,"fork":false,"pushed_at":"2026-01-12T15:27:29.000Z","size":755,"stargazers_count":15,"open_issues_count":2,"forks_count":8,"subscribers_count":1,"default_branch":"master","last_synced_at":"2026-01-12T20:11:09.608Z","etag":null,"topics":["bitbucket","cli","command-line"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/gildas.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2023-12-15T03:03:18.000Z","updated_at":"2026-01-12T15:31:25.000Z","dependencies_parsed_at":"2024-05-05T12:23:42.893Z","dependency_job_id":"023bcfba-000e-48e5-a4eb-bd73790d01fe","html_url":"https://github.com/gildas/bitbucket-cli","commit_stats":null,"previous_names":["gildas/bb","gildas/bitbucket-cli"],"tags_count":24,"template":false,"template_full_name":null,"purl":"pkg:github/gildas/bitbucket-cli","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gildas%2Fbitbucket-cli","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gildas%2Fbitbucket-cli/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gildas%2Fbitbucket-cli/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gildas%2Fbitbucket-cli/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gildas","download_url":"https://codeload.github.com/gildas/bitbucket-cli/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gildas%2Fbitbucket-cli/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28731223,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-24T10:24:43.181Z","status":"ssl_error","status_checked_at":"2026-01-24T10:24:36.112Z","response_time":89,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bitbucket","cli","command-line"],"created_at":"2025-06-21T08:08:54.520Z","updated_at":"2026-02-09T02:07:58.659Z","avatar_url":"https://github.com/gildas.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Bitbucket Command Line Interface\n\n[bb](https://github.com/gildas/bitbucket-cli) is the missing command line interface for Bitbucket. It brings the power of the Bitbucket platform to your command line. Creating and merging Pull Requests, cloning repositories, and more are now just a few keystrokes away.\n\n## Installation\n\n### Linux\n\nYou can grab the latest Debian/Ubuntu package on the [Downloads](https://github.com/gildas/bitbucket-cli/releases) pages.\n\nIf you use [Homebrew](https://brew.sh), you can install `bb` with:\n\n```bash\nbrew install gildas/tap/bitbucket-cli\n```\n\nYou can also install `bb` with snap:\n\n```bash\nsudo snap install bitbucket-cli\nsudo snap alias bitbucket-cli bb\n```\n\n[![Get it from the Snap Store](https://snapcraft.io/static/images/badges/en/snap-store-black.svg)](https://snapcraft.io/bitbucket-cli)\n\n### macOS\n\nYou can get `bb` from [Homebrew](https://brew.sh) with:\n\n```bash\nbrew install gildas/tap/bitbucket-cli\n```\n\n### Windows\n\nYou can get `bb` from [Chocolatey](https://chocolatey.org) with:\n\n```bash\nchoco install bitbucket-cli\n```\n\nYou can also install `bb` with [scoop](https://scoop.sh):\n\n```bash\nscoop bucket add gildas https://github.com/gildas/scoop-bucket\nscoop install bitbucket-cli\n```\n\n### Binaries\n\nYou can download the latest version of `bb` from the [downloads](https://github.com/gildas/bitbucket-cli/releases) page.\n\nOnce you get the `bb` executable, you can install/copy it anywhere in your `$PATH`.\n\n## Usage\n\n`bb` is a modern command line interface. It uses subcommands to perform actions. You can get help on any subcommand by running `bb \u003csubcommand\u003e --help`.\n\nGeneral help is also available by running `bb --help` or `bb help`.\n\nBy default `bb` works in the current git repository. You can specify a Bitbucket repository with the `--repository` flag.\n\nMany commands and flags are dynamically auto-completed. See the [Completion](#completion) section for more information about completion.\n\nMost `delete`, `upload`, and `download` commands support multiple arguments. You can pass a list of arguments or a file with one argument per line:\n\n```bash\nbb repo delete myrepository1 myrepository2 myrepository3\n```\n\nYou can tell `bb` to stop on the first error, warn on errors, or ignore errors when processing multiple arguments with the `--stop-on-error`, `--warn-on-error`, or `--ignore-errors` flags.\n\nAll commands that would modify something on Bitbucket now allow you to preview the changes before applying them. You can use the `--dry-run` flag to see what would happen.\n\n```bash\nbb repo delete myrepository3 --dry-run\n```\n\n`get` and `list` commands support the `--columns` flag to specify which columns to display in the output. You can pass a comma-separated list of columns, repeat the flag, or use `all` to display all columns. If you do not provide this flag, the default columns are displayed.\n\n```bash\nbb repo list --columns all\nbb repo list --columns name,slug,project\nbb repo list --columns name --columns slug\n```\n\n`list` commands also support the `--sort` flag to sort the output by a specific column. You can pass a comma-separated list of columns, repeat the flag, or use `all` to sort by all columns. If you do not provide this flag, the default sorting is used.\n\n```bash\nbb repo list --sort name\n```\n\n`list` commands also support the `--query` flag to filter the output by a specific query. The query syntax is similar to the one used in the Bitbucket web interface. For example, to filter Pull Requests updated after a specific date:\n\n```bash\nbb pullrequest list --query 'updated_on \u003e 2025-12-31'\n```\n\nPlease refer to the [Bitbucket API documentation](https://developer.atlassian.com/cloud/bitbucket/rest/intro/#filtering) for more information about the supported query syntax and fields.\n\n`list` commands also support the 'page-length' flag to set the number of items to retrieve per request to Bitbucket API at a time. By default, the page length is set on the profile and the default is 50. You can set it to a value between 1 and 100.\n\n```bash\nbb repo list --page-length 25\n```\n\n### Output\n\n`bb` outputs a table by default. You can change the output format with the `--output` flag,  by setting the `BB_OUTPUT_FORMAT` environment variable, or by modifying the profile configuration (See [Profiles](#profiles)).\n\nThe following formats are supported:\n\n- `csv`: CSV\n- `json`: JSON\n- `yaml`: YAML\n- `tsv`: TSV\n- `table`: Table\n\nFor example:\n\n```bash\nbb --output json workspace list\n```\n\nOr\n\n```bash\nbb workspace list --output json\n```\n\nChanging the format with the environment variable `BB_OUTPUT_FORMAT` can be done like this:\n\n```bash\nexport BB_OUTPUT_FORMAT=json\nbb workspace list\n```\n\nThe Table output format displays the data in a human-readable format. Here is an example of the output for the `bb pullrequest list` command:\n\n```bash\n$ bb pr list --state all\n+----+---------------------------+--------------------------------+---------------------+-------------+----------+\n| ID |           TITLE           |          DESCRIPTION           |       SOURCE        | DESTINATION |  STATE   |\n+----+---------------------------+--------------------------------+---------------------+-------------+----------+\n|  1 | Merge feature/links       | Feature links. Do not delete   | feature/links       | dev         | DECLINED |\n|    |                           | the feature branch after the   |                     |             |          |\n|    |                           | merge.                         |                     |             |          |\n|  2 | Merge feature/links       | Feature links. Do not delete   | feature/links       | dev         | MERGED   |\n|    |                           | the feature branch after the   |                     |             |          |\n|    |                           | merge.                         |                     |             |          |\n|  3 | Merge release/1.0.0       | Feature 1.0.0. Do not delete   | release/1.0.0       | master      | MERGED   |\n|    |                           | the feature branch after the   |                     |             |          |\n|    |                           | merge.                         |                     |             |          |\n|  4 | Merge feature/bb          | Feature bb. Do not delete the  | feature/bb          | dev         | DECLINED |\n|    |                           | feature branch after the merge |                     |             |          |\n|  5 | Merge feature/bb          | Feature bb. Do not delete the  | feature/bb          | dev         | MERGED   |\n|    |                           | feature branch after the merge |                     |             |          |\n|  6 | Merge feature/bb-doc      | Feature bb-doc. Do not delete  | feature/bb-doc      | dev         | MERGED   |\n|    |                           | the feature branch after the   |                     |             |          |\n|    |                           | merge.                         |                     |             |          |\n+----+---------------------------+--------------------------------+---------------------+-------------+----------+\n```\n\n### Profiles\n\n`bb` uses profiles to store your Bitbucket credentials. You can create a profile with the `bb profile create` command:\n\n```bash\nbb profile create \\\n  --name myprofile \\\n  --client-id \u003cyour-client-id\u003e \\\n  --client-secret \u003cyour-client-secret\u003e \\\n  --callback-port 8080\n```\n\nYou can also pass the `--default` flag to make this profile the default one, or pass a `--output` flag to change the profile output format.\n\nYou can also pass the `--default-workspace` and/or `--default-project` flags to set the default workspace and/or project for this profile.\n\nYou can also pass the `--progress` flag to display a progress bar when upload/downloading artifacts and attachments.\n\nBy default, the password or client secret is stored in the vault of the operating system (Windows Credential Manager, macOS Keychain, or Linux Secret Service). You can pass the `--no-vault` flag to disable this feature and store the password or client secret in plain text in the configuration file. This is not recommended, but can be useful for testing purposes.\n\nProfiles support the following authentications:\n\n- [OAuth 2.0 with Authorization Code Grant](https://developer.atlassian.com/cloud/bitbucket/rest/intro/#1--authorization-code-grant--4-1-) with the `--client-id`, `--client-secret`, and `--callback-port` flags\n- [OAuth 2.0 with Client Credentials](https://developer.atlassian.com/cloud/bitbucket/rest/intro/#3--client-credentials-grant--4-4-) with the `--client-id` and `--client-secret` flags\n- [App passwords](https://support.atlassian.com/bitbucket-cloud/docs/app-passwords/) with the `--user` and `--password` flags.\n- [Repository Access Tokens](https://support.atlassian.com/bitbucket-cloud/docs/repository-access-tokens/), [Project Access Tokens](https://support.atlassian.com/bitbucket-cloud/docs/project-access-tokens/), [Workspace Access Tokens](https://support.atlassian.com/bitbucket-cloud/docs/workspace-access-tokens/) with the `--access-token` flags.\n\nWhen you use a username/password, the password is stored in the vault of the operating system (Windows Credential Manager, macOS Keychain, or Linux Secret Service). You can pass the `--no-vault` flag to disable this feature and store the password in plain text in the configuration file. This is not recommended, but can be useful for testing purposes. On Linux and macOS, you can also pass the `--vault-key` flag to set the key to use in the system keychain. By default, the key is `bitbucket-cli`. On Windows, this option is not available.\n\nYou can also pass the `--clone-protocol` flag to set the default protocol to use when cloning repositories. The supported protocols are `https`, `git`, and `ssh`. This option can be overridden with the `--protocol` flag when using `repo clone`.\n\nIn case you are not using a user/password, you can also pass a `--clone-user` flag to set the username to use when cloning repositories with the `https` protocol. If you use a user/password, you don't need to set this flag, usually, ans the username will be used for cloning repositories. This option can be overridden with the `--user` flag when using `repo clone`.\n\nYou can get the list of your profiles with the `bb profile list` command:\n\n```bash\nbb profile list\n```\n\nYou can get the details of a profile with the `bb profile get` or `bb profile show` command:\n\n```bash\nbb profile get myprofile\n```\n\nYou can ge the details of the current profile:\n\n```bash\nbb profile get --current\n```\n\nOr:\n\n```bash\nbb profile which\n```\n\nYou can update a profile with the `bb profile update` command:\n\n```bash\nbb profile update myprofile \\\n  --client-id \u003cyour-client-id\u003e \\\n  --client-secret \u003cyour-client-secret\u003e\n```\n\nYou can delete a profile with the `bb profile delete` command:\n\n```bash\nbb profile delete myprofile\n```\n\nYou can set the default profile with the `bb profile use` command:\n\n```bash\nbb profile use myprofile\n```\n\nYou can also set the profile with the environment variable `BB_PROFILE`:\n\n```bash\nexport BB_PROFILE=myprofile\n```\n\nThe profile can also come from your current `.git/config` file. You can set the `bb.profile` variable in the `[bitbucket \"cli\"]` section of your `.git/config` file:\n\n```ini\n[bitbucket \"cli\"]\n  profile = myprofile\n```\n\n```bash\ngit config --local bitbucket.cli.profile myprofile\n```\n\nThe current profile comes in order from:\n\n- the `--profile` flag\n- the `BB_PROFILE` environment variable\n- the `profile` variable in the `[bitbucket \"cli\"]` section of your `.git/config` file,  \n  if the profile does not exist, the command will print a warning and use the default profile\n- the profile marked `default` in the configuration file\n- the first profile in the configuration file\n\nProfiles are stored in the configuration file. By default, the configuration file is located:\n\n- on Linux: `$XDG_CONFIG_HOME/bitbucket/config-cli.json`, or `~/.config/bitbucket/config-cli.json`, then `~/.bitbucket-cli`\n- on macOS: `$HOME/Library/Application Support/bitbucket/config-cli.json`, then `~/.bitbucket-cli`\n- on Windows: `%AppData%\\bitbucket\\config-cli.json`, then `$HOME/.bitbucket-cli`\n- on Plan 9: `$home/lib/bitbucket/config-cli.json`, then `~/.bitbucket-cli`\n\nYou can also override the location of the configuration file with the environment variable `BB_CONFIG` or the `--config` flag:\n\n```bash\nexport BB_CONFIG=~/.bb/config.json\n```\n\n```bash\nbb --config ~/.bb/config.json workspace list\n```\n\n#### Adding an OAUTH 2.0 Profile\n\nTo add an OAuth 2.0 profile, you need to create an OAuth consumer on Bitbucket. First, go to the settings page \u003chttps://bitbucket.org/xxxx/workspace/settings\u003e of the Bitbucket workspace you want a consumer for (where `xxxx` is the workspace name/ID). On that page, click on the `OAuth consumers` link in the `Access management` section. Then click on the `Add consumer` button. Fill in the form.\n\nTo use an [OAuth 2.0 with Authorization Code Grant](https://developer.atlassian.com/cloud/bitbucket/rest/intro/#1--authorization-code-grant--4-1-), you will need to fill in the `Callback URL` with a link like \u003chttp://localhost:yyyy\u003e (where `yyyy` is the port you want to use and provide to the `--callback-port` flag of `bb profile create`) and **do not** enable the check box for `This is a private consumer`.\n\nTo use an [OAuth 2.0 with Client Credentials](https://developer.atlassian.com/cloud/bitbucket/rest/intro/#3--client-credentials-grant--4-4-), you will need to enable the check box for `This is a private consumer` and add a _dummy_ `Callback URL`.\n\nIn both cases, you will need to fill in the permissions you want to grant to the consumer.\n\nOnce you hit the `Save` button, your OAuth consumer will be created and you can use the credentials (client identifier and secret) provided to configure your profile with `bb`.\n\nOnce the profile is created in `bb`, for an [OAuth 2.0 with Authorization Code Grant](https://developer.atlassian.com/cloud/bitbucket/rest/intro/#1--authorization-code-grant--4-1-), you will need to authorize the profile with the following command:\n\n```bash\nbb profile authorize myprofile\n```\n\nYou can also use the `--verbose` to get some information about the authorization process.\n\n### Users\n\nYou can get the details of your user with the `bb user me` command:\n\n```bash\nbb user me\n```\n\nYou can get the details of a user with the `bb user get` or `bb user show` command:\n\n```bash\nbb user get {UUID}\n```\n\nOr,\n\n```bash\nbb user get UUID\n```\n\n### Workspaces\n\nYou can list workspaces with the `bb workspace list` command:\n\n```bash\nbb workspace list\n```\n\nWith the `--membership` flag, you can see the kind of membership you have in each workspace:\n\n```bash\nbb workspace list --membership\n```\n\nYou can also get the details of a workspace with the `bb workspace get` or `bb workspace show` command:\n\n```bash\nbb workspace get myworkspace\n```\n\nAdditionally, you can get the members of a workspace with the flag `--members`:\n\n```bash\nbb workspace get myworkspace --members\n```\n\nOr, even, a specific member with the flag `--member`:\n\n```bash\nbb workspace get myworkspace --member mymember\n```\n\nYou can get your permission in a workspace with the `bb workspace permission get` command:\n\n```bash\nbb workspace permission get myworkspace\n```\n\nYou can list all user permissions in a workspace with the `bb workspace permission list` command:\n\n```bash\nbb workspace permission list myworkspace\n```\n\n### Projects\n\nYou can list projects with the `bb project list` command. If the `--workspace` flag is not provided, the default workspace of the profile is used (if the profile does not have a default workspace, the command will fail):\n\n```bash\nbb project list --workspace myworkspace\n```\n\nThe `--workspace` flag is also dynamically auto-completed with the workspaces you have access to.\n\nYou can also get the details of a project with the `bb project get` or `bb project show` command:\n\n```bash\nbb project get myproject --workspace myworkspace\n```\n\nYou can create a project with the `bb project create` command:\n\n```bash\nbb project create \\\n  --name myproject \\\n  --key MYPROJECT\n```\n\nYou can update a project with the `bb project update` command:\n\n```bash\nbb project update myproject \\\n  --name myproject\n```\n\nYou can delete a project with the `bb project delete` command:\n\n```bash\nbb project delete myproject\n```\n\n#### Project Default Reviewers\n\nYou can list the default reviewers of a project with the `bb project reviewer list` command. In addition to the `--workspace`, if the `--project` flag is not provided, the default project of the workspace is used (if the workspace does not have a default project, the command will fail):\n\n```bash\nbb project reviewer list --workspace myworkspace --project myproject\n```\n\nYou can add a default reviewer to a project with the `bb project reviewer add` command:\n\n```bash\nbb project reviewer add userUUID\n```\n\nThe `{}` around the `userUUID` are optional.\n\nYou can remove a default reviewer from a project with the `bb project reviewer remove` command:\n\n```bash\nbb project reviewer remove userUUID\n```\n\n You can get the details of a default reviewer with the `bb project reviewer get` or `bb project reviewer show` command:\n\n```bash\nbb project reviewer get \\\n  --workspace myworkspace \\\n  --project myproject \\\n  userUUID\n```\n\n### Repositories\n\nYou can list repositories with the `bb repo list` command:\n\n```bash\nbb repo list --workspace myworkspace\n```\n\nIf you do not provide a workspace, the command will attempt to list all repositories you have access to, which can take a very long time.\n\nYou can narrow down the list of repositories with the `--role`, `--project`, `--project-key`, `--has-issues`, `--has-wiki`, `--is-private`, `--language`, and `--main-branch` flags:\n\n```bash\nbb repo list --workspace myworkspace \\\n  --role        owner \\\n  --project     myproject \\\n  --has-issues  true \\\n  --has-wiki    true \\\n  --is-private  false \\\n  --language    go \\\n  --main-branch master\n```\n\nAll filterers are optional and combined with an AND operator.\n\nYou can also get the details of a repository with the `bb repo get` or `bb repo show` command. If the `--workspace` flag is not provided, the default workspace of the profile is used (if the profile does not have a default workspace, the command will fail):\n\n```bash\nbb repo get --workspace myworkspace myrepository\n```\n\nYou can clone a repository with the `bb repo clone` command:\n\n```bash\nbb repo clone myworkspace/myrepository\n```\n\nYou can set the protocol to use when cloning a repository with the `--protocol` flag. The supported protocols are `https`, `git`, and `ssh`. If not provided, the protocol set in the profile is used (if the profile does not have a protocol set, the default is `git`).\n\nWhen using the `ssh` protocol, you can specify the SSH key to use with the `--ssh-key-file` flag. If not provided, the key set in the profile is used (if the profile does not have a key set, the default is `~/.ssh/id_rsa`).\n\nWhen using the `https` protocol while cloning a private repository, you can specify the username to use for authentication with the `--user` flag. If the username is not provided, the `cloneUser` from the profile is used. If the profile does not have a `cloneUser`, you cannot clone a private repository with the `https` protocol.\n\nor, with the `--workspace` flag:\n\n```bash\nbb repo clone --workspace myworkspace myrepository\n```\n\nOr, using the profile's default workspace:\n\n```bash\nbb repo clone myrepository\n```\n\nBy default, the repository is cloned in a folder with the same name as the repository. You can specify a different folder with the `--destination` flag:\n\n```bash\nbb repo clone --workspace myworkspace --destination myfolder myrepository\n```\n\nBy default, the repository is cloned using the `git` protocol. You can change the protocol with the `--clone-protocol` flag. The supported protocols are `https`, `git`, and `ssh`. The default protocol can also be set in the profile with the `--clone-protocol` flag when creating or updating a profile.\n\n```bash\nbb repo clone --clone-protocol https myrepository\n```\n\nWhen using the ssh protocol, you can also specify the SSH key to use with the `--ssh-key` flag (by default the key configured is SSH for bitbucket.org is used, and if nothing is configured: `~/.ssh/id_rsa`):\n\n```bash\nbb repo clone --ssh-key /path/to/ssh/key myrepository\n```\n\nWhen using the `https` protocol while cloning a private repository, you can specify the username to use for authentication with the `--username` flag. If the username is not provided, the `cloneVaultUsername` from the profile is used. If the profile does not have a `cloneVaultUsername`, you cannot clone a private repository with the `https` protocol.\n\nOn Linux and macOS, the system keychain will be used to retrieve the credentials. You can set the `cloneVaultKey` in the profile to use a specific key in the keychain. If not set, the default value is `bitbucket-cli-clone`. You can also set the `cloneVaultUsername` in the profile to use a specific username for authentication.  \nOn Windows, the Windows Credential Manager will be used to retrieve the credentials. And the username should be `\u003ccloneVaultKey\u003e:\u003ccloneVaultUsername\u003e`.\n\n```bash\nbb repo clone --username myusername myrepository\n```\n\nYou can create a repository with the `bb repo create` command:\n\n```bash\nbb repo create myrepository_slug \\\n  --name      myrepository \\\n  --project   myproject \\\n  --workspace myworkspace\n```\n\nIf the `--project` flag is not provided, the repository will be created in the default project of the profile.\n\nYou can update a repository with the `bb repo update` command:\n\n```bash\nbb repo update --workspace myworkspace myrepository \\\n  --private \\\n  --fork-policy no_public_forks\n```\n\nYou can delete a repository with the `bb repo delete` command:\n\n```bash\nbb repo delete --workspace myworkspace myrepository\n```\n\nYou can fork a repository with the `bb repo fork` command:\n\n```bash\nbb repo fork myrepository \\\n  --workspace myworkspace \\\n  --project   myproject \\\n  --name      myfork\n```\n\nYou can list the forks of a repository with the `bb repo get --forks` command:\n\n```bash\nbb repo get myrepository \\\n  --workspace myworkspace \\\n  --forks\n```\n\n### Pull Requests\n\nYou can list pull requests with the `bb pullrequest list` command:\n\n```bash\nbb pullrequest list\n```\n\nYou can create a pull request with the `bb pullrequest create` command:\n\n```bash\nbb pullrequest create \\\n  --title \"My pull request\" \\\n  --source \"my-branch\" \\\n  --destination \"master\"\n```\n\nYou can add reviewers to the pull request with the `--reviewer` flag:\n\n```bash\nbb pullrequest create \\\n  --title \"My pull request\" \\\n  --source \"my-branch\" \\\n  --destination \"master\" \\\n  --reviewer    username1 --reviewer {userUUID2}\n```\n\nIf the first reviewer is `default`, the command will try to get the default reviewers from the project settings.\n\nYou can get the details of a pull request with the `bb pullrequest get` or `bb pullrequest show` command:\n\n```bash\nbb pullrequest get 1\n```\n\nYou can also modify a pull request with the `bb pullrequest update` command:\n\n```bash\nbb pullrequest update 1 \\\n  --title \"My pull request\" \\\n  --description \"My pull request description\"\n```\n\nTo add or remove reviewers from a pull request, you can use the `--add-reviewer` and `--remove-reviewer` flags:\n\n```bash\nbb pullrequest update 1 \\\n  --add-reviewer    username1 --add-reviewer {userUUID2} \\\n  --remove-reviewer username3 --remove-reviewer {userUUID4}\n```\n\nYou can `approve`or `unapprove` a pull request with the `bb pullrequest approve` or `bb pullrequest unapprove` command:\n\n```bash\nbb pullrequest approve 1\n```\n\nYou can `decline` a pull request with the `bb pullrequest decline` command:\n\n```bash\nbb pullrequest decline 1\n```\n\nYou can `merge` a pull request with the `bb pullrequest merge` command:\n\n```bash\nbb pullrequest merge 1\n```\n\nIf no pull request is provided, the command will try to merge the pull request with the current branch.\n\nYou can list the comments of a pull request with the `bb pullrequest comment list` command:\n\n```bash\nbb pullrequest comment list --pullrequest 1\n```\n\nYou can add a comment to a pull request with the `bb pullrequest comment create` or `bb pullrequest comment add` command:\n\n```bash\nbb pullrequest comment add --pullrequest 1 \\\n  --comment \"My comment\" \\\n  --file    README.md \\\n  --line    404\n```\n\nYou can resolve a comment with the `bb pullrequest comment resolve` command:\n\n```bash\nbb pullrequest comment resolve --pullrequest 1 452466\n```\n\nYou can re-open a comment with the `bb pullrequest comment reopen` command:\n\n```bash\nbb pullrequest comment reopen --pullrequest 1 452466\n```\n\nYou can get the details of a comment with the `bb pullrequest comment get` or `bb pullrequest comment show` command:\n\n```bash\nbb pullrequest comment get --pullrequest 1 452466\n```\n\nYou can update a comment with the `bb pullrequest comment update` command:\n\n```bash\nbb pullrequest comment update --pullrequest 1 452466 \\\n  --comment \"My comment\"\n```\n\nYou can delete a comment with the `bb pullrequest comment delete` command:\n\n```bash\nbb pullrequest comment delete --pullrequest 1 452466\n```\n\n### Issues\n\nYou can list issues with the `bb issue list` command:\n\n```bash\nbb issue list\n```\n\nBy default, all open and new issues are listed. You can use the `--state` flag to filter the issues by state:\n\n```bash\nbb issue list --state open\n```\n\nThe flag `--state` can be used multiple times to filter by multiple states:\n\n```bash\nbb issue list --state open --state new --state resolved,wontfix\n```\n\nYou can create an issue with the `bb issue create` command:\n\n```bash\nbb issue create \\\n  --title \"My issue\" \\\n  --content \"My issue content\"\n```\n\nYou can get the details of an issue with the `bb issue get` or `bb issue show` command:\n\n```bash\nbb issue get 1\n```\n\nYou can update an issue with the `bb issue update` command:\n\n```bash\nbb issue update 1 \\\n  --title \"My issue\" \\\n  --content \"My issue content\"\n```\n\nYou can delete an issue with the `bb issue delete` command:\n\n```bash\nbb issue delete 1\n```\n\nYou can vote for an issue with the `bb issue vote` command:\n\n```bash\nbb issue vote 1\n```\n\nYou can unvote for an issue with the `bb issue unvote` command:\n\n```bash\nbb issue unvote 1\n```\n\nYou can watch an issue with the `bb issue watch` command:\n\n```bash\nbb issue watch 1\n```\n\nYou can unwatch an issue with the `bb issue unwatch` command:\n\n```bash\nbb issue unwatch 1\n```\n\nYou can add a comment to an issue with the `bb issue comment create` or `bb issue comment add` command:\n\n```bash\nbb issue comment add --issue 1 \\\n  --content \"My comment\"\n```\n\nYou can get the details of a comment with the `bb issue comment get` or `bb issue comment show` command:\n\n```bash\nbb issue comment get --issue 1 7643545\n```\n\nYou can update a comment with the `bb issue comment update` command:\n\n```bash\nbb issue comment update --issue 1 7643545 \\\n  --content \"My comment\"\n```\n\nYou can delete a comment with the `bb issue comment delete` command:\n\n```bash\nbb issue comment delete --issue 1 7643545\n```\n\nYou can list the attachments of an issue with the `bb issue attachment list` command:\n\n```bash\nbb issue attachment list --issue 1\n```\n\nYou can upload an attachment to an issue with the `bb issue attachment upload` command:\n\n```bash\nbb issue attachment upload --issue 1 myattachment.zip\n```\n\nYou can download an attachment with the `bb issue attachment download` command:\n\n```bash\nbb issue attachment download --issue 1 myattachment.zip\n```\n\nYou can delete an attachment with the `bb issue attachment delete` command:\n\n```bash\nbb issue attachment delete --issue 1 myattachment.zip\n```\n\n### Artifacts (Downloads)\n\nYou can list artifacts with the `bb artifact list` command:\n\n```bash\nbb artifact list\n```\n\nBy default the current repository is used, you can specify a repository with the `--repository` flag.\n\nYou can also upload an artifact with the `bb artifact upload` command:\n\n```bash\nbb artifact upload myartifact.zip\n```\n\nAt the moment, only one file at a time is supported (no folders or stdin). The artifact name is the file name.\n\nYou can download an artifact with the `bb artifact download` command:\n\n```bash\nbb artifact download myartifact.zip\n```\n\nYou can provide a `--destination` flag to specify the destination folder. If the folder does not exist, it will be created.\n\nYou can also pass the `--progress` flag to display a progress bar when upload/downloading artifacts. This override the default value set at the Profile level.\n\nFinally, you can delete an artifact with the `bb artifact delete` command:\n\n```bash\nbb artifact delete myartifact.zip\n```\n\n### Pipelines\n\nYou can list pipelines with the `bb pipeline list` command:\n\n```bash\nbb pipeline list\n```\n\nBy default the current repository is used, you can specify a repository with the `--repository` flag.\n\nYou can get the details of a pipeline with the `bb pipeline get` or `bb pipeline show` command:\n\n```bash\nbb pipeline get 123456\n```\n\nYou can start a pipeline with the `bb pipeline trigger` command:\n\n```bash\nbb pipeline trigger --branch master --variable KEY1=VALUE1 --variable KEY2=VALUE2\n```\n\nBy default, the pipeline is started on the current branch. You can also specify a tag or a commit with the `--tag` or `--commit` flags instead of a branch.\n\nYou can stop a running pipeline with the `bb pipeline stop` command:\n\n```bash\nbb pipeline stop 123456\n```\n\nYou can get the list of the steps of a pipeline with the `bb pipeline step list` command:\n\n```bash\nbb pipeline step list --pipeline 123456\n```\n\nYou can get the details of a step with the `bb pipeline step get` or `bb pipeline step show` command:\n\n```bash\nbb pipeline step get --pipeline 123456 {stepUUID}\n```\n\nYou can get the logs of a step with the `bb pipeline step log` command:\n\n```bash\nbb pipeline step logs --pipeline 123456 {stepUUID}\n```\n\n### GPG Keys\n\nYou can list GPG keys with the `bb key list` command:\n\n```bash\nbb gpg-key list\n```\n\nBy default, the keys are listed for the current user. You can specify a user with the `--user` flag.\n\nYou can also get the details of a GPG key with the `bb key get` or `bb key show` command:\n\n```bash\nbb gpg-key get \u003cfingerprint\u003e\n```\n\nBy default, the key is retrieved for the current user. You can specify a user with the `--user` flag.\n\nYou can create a GPG key with the `bb gpg-key create` command:\n\n```bash\nbb gpg-key create \\\n  --user \u003cuser\u003e \\\n  --name \u003ckeyname\u003e \\\n  --key \u003ckey\u003e\n```\n\nThe key name is optional. You can also provide the key in a file with the `--key-file` flag. If the filename is `-`, the key is read from stdin. If the `--user` flag is not provided, the key is created for the user associated with the current profile.\n\nYou can delete one or more GPG keys with the `bb gpg-key delete` command:\n\n```bash\nbb gpg-key delete \u003cfingerprint\u003e\n```\n\n### SSH Keys\n\nYou can list SSH keys with the `bb key list` command:\n\n```bash\nbb ssh-key list\n```\n\nBy default, the keys are listed for the current user. You can specify a user with the `--user` flag.\n\nYou can also get the details of an SSH key with the `bb ssh-key get` or `bb ssh-key show` command:\n\n```bash\nbb ssh-key get \u003cfingerprint\u003e\n```\n\nBy default, the key is retrieved for the current user. You can specify a user with the `--user` flag.\n\nYou can create an SSH key with the `bb ssh-key create` command:\n\n```bash\nbb ssh-key create \\\n  --user \u003cuser\u003e \\\n  --name \u003ckeyname\u003e \\\n  --key \u003ckey\u003e\n```\n\nThe key name is optional. You can also provide the key in a file with the `--key-file` flag. If the filename is `-`, the key is read from stdin. If the `--user` flag is not provided, the key is created for the user associated with the current profile.\n\nYou can delete one or more SSH keys with the `bb ssh-key delete` command:\n\n```bash\nbb ssh-key delete \u003cfingerprint\u003e\n```\n\n### Cache\n\nThe bitbucket-cli caches some data to speed up the commands. The following items are cached:\n\n- workspaces\n- projects\n- users\n\nThe cache is stored in the [os.UserCacheDir](https://pkg.go.dev/os#UserCacheDir) directory, under `bitbucket`. The values are stored for a duration of 5 minutes, you can override this value with the environment variable `BITBUCKET_CLI_CACHE_DURATION` (for the format please follow [core.ParseDuration](https://pkg.go.dev/github.com/gildas/go-core#ParseDuration)). By default, the items are stored as JSON files unencrypted. To encrypt these files, you can set the environment variable `BITBUCKET_CLI_CACHE_ENCRYPTIONKEY` with an AES-256 key. The key must follow the [crypto/aes](https://pkg.go.dev/crypto/aes) requirements.\n\nYou can clear the cache with the `bb cache clear` command:\n\n```bash\nbb cache clear\n```\n\n### Completion\n\n`bb` supports completion for Bash, fish, Powershell, and zsh.\n\n#### Bash\n\nTo enable completion, run the following command:\n\n```bash\nsource \u003c(bb completion bash)\n```\n\nYou can also add this line to your `~/.bashrc` file to enable completion for every new shell.\n\n```bash\nbb completion bash \u003e ~/.bashrc\n```\n\n#### fish\n\nTo enable completion, run the following command:\n\n```bash\nbb completion fish | source\n```\n\nYou can also add this line to your `~/.config/fish/config.fish` file to enable completion for every new shell.\n\n```bash\nbb completion fish \u003e ~/.config/fish/completions/bb.fish\n```\n\n#### Powershell\n\nTo enable completion, run the following command:\n\n```pwsh\nbb completion powershell | Out-String | Invoke-Expression\n```\n\nYou can also add the output of the above command to your `$PROFILE` file to enable completion for every new shell.\n\n#### zsh\n\nTo enable completion, run the following command:\n\n```bash\nsource \u003c(bb completion zsh)\n```\n\nYou can also add this line to your functions folder to enable completion for every new shell.\n\n```bash\nbb completion zsh \u003e \"~/${fpath[1]}/_bb\"\n```\n\nOn macOS, you can add the completion to the brew functions:\n\n```bash\nbb completion zsh \u003e \"$(brew --prefix)/share/zsh/site-functions/_bb\"\n```\n\n## TODO\n\nWe will add more commands in the future. If you have any suggestions, please open an issue.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgildas%2Fbitbucket-cli","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgildas%2Fbitbucket-cli","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgildas%2Fbitbucket-cli/lists"}