Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
9090881
forge: Add Bitbucket Data Center support to the bitbucket forge
kanchev1 Jun 7, 2026
109e3eb
Merge branch 'main' into feat/bitbucket-server-forge
kanchev1 Jun 14, 2026
985c01e
Merge branch 'main' into feat/bitbucket-server-forge
kanchev1 Jun 15, 2026
a0a0cf3
Merge main into Bitbucket Server forge
abhinav Jul 3, 2026
1680863
[autofix.ci] apply automated fixes
autofix-ci[bot] Jul 3, 2026
810d0f0
Merge branch 'main' into feat/bitbucket-server-forge
abhinav Jul 5, 2026
c74add5
fix(bitbucket): Use repository URL for server gateway
abhinav Jul 5, 2026
a14d5de
fix(bitbucket): Preserve personal REST project keys
abhinav Jul 5, 2026
e3b0781
[autofix.ci] apply automated fixes
autofix-ci[bot] Jul 3, 2026
f75c0b2
fix(bitbucket): Query mergeability through gateways
abhinav Jul 5, 2026
39dc1fa
Merge branch 'feat/bitbucket-server-forge' from PR
abhinav Jul 5, 2026
f8a67f2
refactor(forge): Construct forges from definitions
abhinav Jul 5, 2026
d173b49
Merge forge construction definitions
abhinav Jul 6, 2026
7ead865
Merge main into feat/bitbucket-server-forge
abhinav Jul 7, 2026
d179114
refactor(bitbucket): Select product during forge construction
abhinav Jul 7, 2026
e0983b0
fix(bitbucket): Satisfy forge construction lint
abhinav Jul 7, 2026
8557def
refactor(bitbucket): Resolve forge product fields once
abhinav Jul 8, 2026
f3c21c9
test(bitbucket): Localize gateway conformance fixtures
abhinav Jul 8, 2026
5882f43
refactor(bitbucket): Inline forge logger selection
abhinav Jul 8, 2026
7d8f8eb
style(bitbucket): Use natural gateway import name
abhinav Jul 8, 2026
484cb65
test(bitbucket): Inline conformance scenarios
abhinav Jul 8, 2026
119971a
test(bitbucket): Simplify conformance wire setup
abhinav Jul 8, 2026
28675c2
refactor(bitbucket): Stream gateway client responses
abhinav Jul 8, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changes/unreleased/Added-20260607-093003.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
kind: Added
body: >-
bitbucket: Self-hosted Bitbucket Data Center / Server instances are now
supported via 'spice.forge.kind=bitbucket' or 'spice.forge.bitbucket.url'.
time: 2026-06-07T09:30:03.9146879+02:00
5 changes: 5 additions & 0 deletions .changes/unreleased/Added-20260611-114253.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
kind: Added
body: >-
bitbucket: New pull request descriptions are now filled from pull request
template files on the default branch.
time: 2026-06-11T11:42:53.8146512+02:00
6 changes: 6 additions & 0 deletions .changes/unreleased/Changed-20260611-114207.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
kind: Changed
body: >-
bitbucket: A custom 'spice.forge.bitbucket.url' is now interpreted as a
Bitbucket Data Center instance unless 'spice.forge.bitbucket.kind=cloud'
is set.
time: 2026-06-11T11:42:07.5312846+02:00
3 changes: 3 additions & 0 deletions doc/hooks/replace.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,16 +11,19 @@
'<!-- gs:github -->': ':simple-github: GitHub',
'<!-- gs:gitlab -->': ':simple-gitlab: GitLab',
'<!-- gs:bitbucket -->': ':simple-bitbucket: Bitbucket',
'<!-- gs:bitbucket-server -->': ':simple-bitbucket: Bitbucket Data Center',
'<!-- gs:gitea -->': ':simple-gitea: Gitea',
'<!-- gs:forgejo -->': ':simple-forgejo: Forgejo',
'<!-- gs:icon:github -->': ':simple-github:',
'<!-- gs:icon:gitlab -->': ':simple-gitlab:',
'<!-- gs:icon:bitbucket -->': ':simple-bitbucket:',
'<!-- gs:icon:bitbucket-server -->': ':simple-bitbucket:',
'<!-- gs:icon:gitea -->': ':simple-gitea:',
'<!-- gs:icon:forgejo -->': ':simple-forgejo:',
'<!-- gs:badge:github ': '<!-- gs:badge simple-github GitHub ',
'<!-- gs:badge:gitlab ': '<!-- gs:badge simple-gitlab GitLab ',
'<!-- gs:badge:bitbucket ': '<!-- gs:badge simple-bitbucket Bitbucket ',
'<!-- gs:badge:bitbucket-server ': '<!-- gs:badge simple-bitbucket Bitbucket Data Center ',
'<!-- gs:badge:gitea ': '<!-- gs:badge simple-gitea Gitea ',
'<!-- gs:badge:forgejo ': '<!-- gs:badge simple-forgejo Forgejo ',
}
Expand Down
2 changes: 1 addition & 1 deletion doc/includes/cli-reference.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ git-spice is a command line tool for stacking Git branches.
* `-C`, `--dir=DIR`: Change to DIR before doing anything
* `--[no-]prompt`: Whether to prompt for missing information

**Configuration**: [spice.forge.bitbucket.apiURL](/cli/config.md#spiceforgebitbucketapiurl), [spice.forge.bitbucket.url](/cli/config.md#spiceforgebitbucketurl), [spice.forge.forgejo.apiURL](/cli/config.md#spiceforgeforgejoapiurl), [spice.forge.forgejo.url](/cli/config.md#spiceforgeforgejourl), [spice.forge.gitea.apiURL](/cli/config.md#spiceforgegiteaapiurl), [spice.forge.gitea.url](/cli/config.md#spiceforgegiteaurl), [spice.forge.github.apiUrl](/cli/config.md#spiceforgegithubapiurl), [spice.forge.github.url](/cli/config.md#spiceforgegithuburl), [spice.forge.gitlab.apiURL](/cli/config.md#spiceforgegitlabapiurl), [spice.forge.gitlab.oauth.clientID](/cli/config.md#spiceforgegitlaboauthclientid), [spice.forge.gitlab.removeSourceBranch](/cli/config.md#spiceforgegitlabremovesourcebranch), [spice.forge.gitlab.url](/cli/config.md#spiceforgegitlaburl), [spice.forge.kind](/cli/config.md#spiceforgekind), [spice.git.indexLockTimeout](/cli/config.md#spicegitindexlocktimeout), [spice.secret.backend](/cli/config.md#spicesecretbackend)
**Configuration**: [spice.forge.bitbucket.apiURL](/cli/config.md#spiceforgebitbucketapiurl), [spice.forge.bitbucket.kind](/cli/config.md#spiceforgebitbucketkind), [spice.forge.bitbucket.url](/cli/config.md#spiceforgebitbucketurl), [spice.forge.forgejo.apiURL](/cli/config.md#spiceforgeforgejoapiurl), [spice.forge.forgejo.url](/cli/config.md#spiceforgeforgejourl), [spice.forge.gitea.apiURL](/cli/config.md#spiceforgegiteaapiurl), [spice.forge.gitea.url](/cli/config.md#spiceforgegiteaurl), [spice.forge.github.apiUrl](/cli/config.md#spiceforgegithubapiurl), [spice.forge.github.url](/cli/config.md#spiceforgegithuburl), [spice.forge.gitlab.apiURL](/cli/config.md#spiceforgegitlabapiurl), [spice.forge.gitlab.oauth.clientID](/cli/config.md#spiceforgegitlaboauthclientid), [spice.forge.gitlab.removeSourceBranch](/cli/config.md#spiceforgegitlabremovesourcebranch), [spice.forge.gitlab.url](/cli/config.md#spiceforgegitlaburl), [spice.forge.kind](/cli/config.md#spiceforgekind), [spice.git.indexLockTimeout](/cli/config.md#spicegitindexlocktimeout), [spice.secret.backend](/cli/config.md#spicesecretbackend)

## Shell

Expand Down
40 changes: 40 additions & 0 deletions doc/src/cli/config.md
Original file line number Diff line number Diff line change
Expand Up @@ -217,6 +217,10 @@ the repository path.
Accepted values are registered forge IDs,
including `github`, `gitlab`, `bitbucket`, `gitea`, and `forgejo`.

With `bitbucket`, the instance URL is derived from the remote URL
when $$spice.forge.bitbucket.url$$ is not set,
so this option alone supports self-hosted Bitbucket instances.

Alternatively, set this option with the `GIT_SPICE_FORGE_KIND`
environment variable.

Expand All @@ -243,6 +247,34 @@ URL at which the Bitbucket API is available.
Defaults to `$BITBUCKET_API_URL` if set,
or `https://api.bitbucket.org/2.0` otherwise.

<!-- gs:version unreleased -->
For Bitbucket Data Center instances,
the API URL defaults to the instance URL
with `/rest/api/1.0` appended.

### spice.forge.bitbucket.kind

<!-- gs:version unreleased -->

The kind of Bitbucket instance that $$spice.forge.bitbucket.url$$ points to.

By default, git-spice infers the kind from the instance URL:
`bitbucket.org` selects Bitbucket Cloud,
and any other URL selects Bitbucket Data Center / Server.
Set this option to override the inference,
e.g. to use the Cloud API behind a custom URL.

**Accepted values:**

- `cloud`: Bitbucket Cloud (REST API 2.0)
- `datacenter` (aliases: `data-center`, `server`): Bitbucket Data Center / Server (REST API 1.0)

Alternatively, set this option with the `BITBUCKET_KIND`
environment variable.

See also
[Bitbucket Data Center / Server](../setup/auth.md#bitbucket-data-center-server).

### spice.forge.bitbucket.url

<!-- gs:version v0.25.0 -->
Expand All @@ -251,6 +283,14 @@ URL of the Bitbucket instance used for Bitbucket requests.
Defaults to `$BITBUCKET_URL` if set,
or `https://bitbucket.org` otherwise.

<!-- gs:version unreleased -->
A custom URL selects a self-hosted Bitbucket Data Center / Server instance
and its REST 1.0 API automatically.
Set $$spice.forge.bitbucket.kind$$ to `cloud` to keep the Cloud API.

See also
[Bitbucket Data Center / Server](../setup/auth.md#bitbucket-data-center-server).

### spice.forge.gitlab.url

<!-- gs:version v0.9.0 -->
Expand Down
5 changes: 3 additions & 2 deletions doc/src/community/faq.md
Original file line number Diff line number Diff line change
Expand Up @@ -123,8 +123,9 @@ and leave them as-is.
## Will git-spice add support for other Git hosting services?

As of writing this, git-spice supports
GitHub, GitLab, Bitbucket Cloud, Gitea, and Forgejo,
including Codeberg.
GitHub, GitLab, Bitbucket Cloud,
self-hosted Bitbucket Data Center / Server, Gitea,
and Forgejo, including Codeberg.
It is specifically designed to support other forges;
most of the code is forge-agnostic,
with forge-specific code is isolated to their own directories inside
Expand Down
41 changes: 37 additions & 4 deletions doc/src/guide/limits.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,12 @@ icon: octicons/stop-16
title: Limitations
description: >-
Usage constraints and limitations when using git-spice
to interact with GitHub, GitLab, Bitbucket Cloud, Gitea, or Forgejo.
to interact with GitHub, GitLab, Bitbucket Cloud,
Bitbucket Data Center / Server, Gitea, or Forgejo.
---

Usage of git-spice with GitHub, GitLab, Bitbucket Cloud, Gitea, and Forgejo
Usage of git-spice with GitHub, GitLab, Bitbucket Cloud,
Bitbucket Data Center / Server, Gitea, and Forgejo
runs into limitations of what is possible on those platforms,
and how they handle Git commits.
Some limitations imposed on git-spice are listed below.
Expand Down Expand Up @@ -135,8 +137,39 @@ compared to GitHub and GitLab:
The `--label` flag is ignored.
- **No PR assignees**: Bitbucket does not support pull request assignees.
The `--assign` flag is ignored.
- **No template enumeration**: Bitbucket does not provide an API
to list pull request templates.
- **Fixed pull request template paths**:
Bitbucket does not provide an API to list pull request templates,
so git-spice reads them from a fixed set of well-known paths
on the default branch:
`PULL_REQUEST_TEMPLATE.md` or `pull_request_template.md`,
at the repository root or inside a `.bitbucket` directory.

These are platform limitations, not git-spice limitations.

## Bitbucket Data Center / Server limitations

<!-- gs:version unreleased -->

Self-hosted Bitbucket Data Center / Server support has some limitations
compared to GitHub and GitLab:

- **No PR labels**: Bitbucket Data Center does not support pull request labels.
The `--label` flag is ignored.
- **No PR assignees**: Bitbucket Data Center does not support pull request assignees.
The `--assign` flag is ignored.
- **Draft PRs require Bitbucket Data Center 8.18+**:
On older servers the draft flag is ignored
and a regular pull request is created.
- **Draft status cannot be toggled after creation**:
A pull request may be created as a draft,
but Bitbucket Data Center does not allow changing its draft status afterward.
The `--draft` and `--ready` flags are ignored when updating an existing PR.
- **No fork / cross-repository PRs**:
Pull requests are supported only between branches in the same repository.
- **Nested task counts require Bitbucket Data Center 7.2+**:
Comment resolution counts (shown by `gs log --cr-comments`)
include tasks; on older servers,
tasks left as replies within a comment thread are not counted.

These are platform limitations, not git-spice limitations.

Expand Down
Loading
Loading