diff --git a/modules/structs/repo.go b/modules/structs/repo.go index 46c62744701..7e92bebe57b 100644 --- a/modules/structs/repo.go +++ b/modules/structs/repo.go @@ -359,6 +359,7 @@ const ( CodeCommitService // 9 codecommit service BitbucketServerService // 10 bitbucket server (data center) service ForgejoService // 11 forgejo service + BitbucketService // 12 bitbucket.org service ) // Name represents the service type's name @@ -390,6 +391,8 @@ func (gt GitServiceType) Title() string { return "Bitbucket Server" case ForgejoService: return "Forgejo" + case BitbucketService: + return "Bitbucket" case PlainGitService: return "Git" } @@ -399,21 +402,12 @@ func (gt GitServiceType) Title() string { // Variants returns the hosting options of gt's provider, which share one entry on the migrate page func (gt GitServiceType) Variants() []GitServiceType { switch gt { - case BitbucketServerService: - return []GitServiceType{BitbucketServerService} + case BitbucketService, BitbucketServerService: + return []GitServiceType{BitbucketService, BitbucketServerService} } return nil } -// ProviderTitle returns the title of gt's entry on the migrate page -func (gt GitServiceType) ProviderTitle() string { - switch gt { - case BitbucketServerService: - return "Bitbucket" - } - return gt.Title() -} - // MigrateRepoOptions options for migrating repository's // this is used to interact with api v1 type MigrateRepoOptions struct { @@ -426,7 +420,7 @@ type MigrateRepoOptions struct { // required: true RepoName string `json:"repo_name" binding:"Required;AlphaDashDot;MaxSize(100)"` - // enum: ["git","github","gitea","gitlab","gogs","onedev","gitbucket","codebase","codecommit","bitbucketserver","forgejo"] + // enum: ["git","github","gitea","gitlab","gogs","onedev","gitbucket","codebase","codecommit","bitbucketserver","forgejo","bitbucket"] Service string `json:"service"` AuthUsername string `json:"auth_username"` AuthPassword string `json:"auth_password"` @@ -464,6 +458,7 @@ var SupportedFullGitService = []GitServiceType{ GithubService, GitlabService, GiteaService, + BitbucketService, ForgejoService, GogsService, OneDevService, diff --git a/options/locale/locale_en-US.json b/options/locale/locale_en-US.json index 06fe859b86d..53153e51b19 100644 --- a/options/locale/locale_en-US.json +++ b/options/locale/locale_en-US.json @@ -1125,7 +1125,9 @@ "repo.migrate.onedev.description": "Migrate data from code.onedev.io or other OneDev instances.", "repo.migrate.codebase.description": "Migrate data from codebasehq.com.", "repo.migrate.gitbucket.description": "Migrate data from GitBucket instances.", - "repo.migrate.bitbucketserver.description": "Migrate data from Bitbucket Data Center or Server instances.", + "repo.migrate.bitbucket.description": "Migrate data from bitbucket.org or Bitbucket Data Center and Server instances.", + "repo.migrate.bitbucket.variant": "Cloud (bitbucket.org)", + "repo.migrate.bitbucket.token_desc": "An Atlassian API token or a repository or workspace access token with read access to repositories and pull requests. Required for private repositories and to raise the API rate limit.", "repo.migrate.bitbucketserver.variant": "Data Center / Server", "repo.migrate.hosting": "Hosting", "repo.migrate.bitbucketserver.token_desc": "HTTP access token. If set, it is used instead of the password above. The username defaults to the owner of the token.", diff --git a/services/convert/utils.go b/services/convert/utils.go index 59a4ff008da..3cfbb5f1bae 100644 --- a/services/convert/utils.go +++ b/services/convert/utils.go @@ -44,6 +44,8 @@ func ToGitServiceType(value string) structs.GitServiceType { return structs.BitbucketServerService case "forgejo": return structs.ForgejoService + case "bitbucket": + return structs.BitbucketService default: return structs.PlainGitService } diff --git a/services/convert/utils_test.go b/services/convert/utils_test.go index f207513ea1b..1ec23b444d2 100644 --- a/services/convert/utils_test.go +++ b/services/convert/utils_test.go @@ -42,6 +42,8 @@ func TestToGitServiceType(t *testing.T) { typ: "bitbucketserver", enum: 10, }, { typ: "forgejo", enum: 11, + }, { + typ: "bitbucket", enum: 12, }} for _, test := range tc { assert.EqualValues(t, test.enum, ToGitServiceType(test.typ)) diff --git a/services/migrations/_mock_data/TestBitbucketDownloadRepo/GET_%2F2.0%2Frepositories%2Fatlassian%2Faui%2Fpullrequests b/services/migrations/_mock_data/TestBitbucketDownloadRepo/GET_%2F2.0%2Frepositories%2Fatlassian%2Faui%2Fpullrequests new file mode 100644 index 00000000000..9c16456db8f --- /dev/null +++ b/services/migrations/_mock_data/TestBitbucketDownloadRepo/GET_%2F2.0%2Frepositories%2Fatlassian%2Faui%2Fpullrequests @@ -0,0 +1,37 @@ +Age: 0 +Atl-Request-Id: 9e13d533-e742-492f-9491-fa70d6b2eeda +Atl-Traceid: 9e13d533e742492f9491fa70d6b2eeda +Cache-Control: max-age=900 +Content-Type: application/json; charset=utf-8 +Etag: W/"d60eb01065df32f229cf7996bf21f149" +Server-Timing: cdn-upstream-layer;desc="EDGE",cdn-upstream-dns;dur=0,cdn-upstream-connect;dur=0,cdn-upstream-fbl;dur=576,atl-edge;dur=469,atl-edge-internal;dur=8,atl-edge-upstream;dur=461,atl-edge-pop;desc="aws-us-east-1",cdn-cache-miss,cdn-pop;desc="VIE50-P1",cdn-rid;desc="G_Q7MMqPH7SRDgKt6XL84kKmqanLAXMocfBKJ_CNFWkF3gHAW_8SCw==",cdn-downstream-fbl;dur=580 +Strict-Transport-Security: max-age=63072000; includeSubDomains; preload +Vary: Authorization, origin +Vary: Accept-Encoding +Via: 1.1 9127bf22c332a88edd7d5939b5870d1e.cloudfront.net (CloudFront) +X-Accepted-Oauth-Scopes: pullrequest +X-Amz-Cf-Id: G_Q7MMqPH7SRDgKt6XL84kKmqanLAXMocfBKJ_CNFWkF3gHAW_8SCw== +X-Amz-Cf-Pop: VIE50-P1 +X-Asap-Succeeded: True +X-B3-Spanid: 54f13123cfd4da4c +X-B3-Traceid: 9e13d533e742492f9491fa70d6b2eeda +X-Cache: Miss from cloudfront +X-Content-Type-Options: nosniff +X-Credential-Type: unauthenticated_identity +X-Dc-Location: Micros-3 +X-Envoy-Attempt-Count: 1 +X-Frame-Options: SAMEORIGIN +X-Render-Time: 0.43766093254089355 +X-Request-Count: 2930 +X-Served-By: 38e679aebd5f +X-Static-Version: 23055ebb54a0 +X-Usage-Input-Ops: 256 +X-Usage-Output-Ops: 0 +X-Usage-System-Time: 0.012903 +X-Usage-User-Time: 0.182562 +X-Used-Mesh: False +X-Version: 23055ebb54a0 +X-View-Name: bitbucket.apps.pullrequests.api.v20.handlers.RepositoryPullRequestsHandler +X-Xss-Protection: 1; mode=block + +{"values": [{"comment_count": 25, "task_count": 0, "type": "pullrequest", "id": 1, "title": "Heading size change and split typography to separate resource", "description": "As discussed at FERM. Will put this on master first then backport as required.", "rendered": {}, "state": "MERGED", "draft": false, "merge_commit": {"type": "commit", "hash": "108d70a532dd8b98166237b54a961958e92f8a96", "date": "2011-11-02T05:23:30+00:00", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/commit/108d70a532dd8b98166237b54a961958e92f8a96"}, "html": {"href": "https://bitbucket.org/atlassian/aui/commits/108d70a532dd8b98166237b54a961958e92f8a96"}}}, "diff_type": 1, "latest_excluded_files_version": "8d74170f-e08f-41d8-8d65-ce063fa86348", "close_source_branch": false, "closed_by": {"display_name": "Jaie Wilson", "links": {"self": {"href": "https://api.bitbucket.org/2.0/users/%7B4035f76b-7370-4a33-86e5-bc906d201811%7D"}, "avatar": {"href": "https://avatar-management--avatars.us-west-2.prod.public.atl-paas.net/557058:5271fe35-ce1c-4d9e-bb7c-93d777bf230d/36a76baa-05bc-4e76-a42b-5f3ce2a3fd1c/128"}, "html": {"href": "https://bitbucket.org/%7B4035f76b-7370-4a33-86e5-bc906d201811%7D/"}}, "type": "user", "uuid": "{4035f76b-7370-4a33-86e5-bc906d201811}", "account_id": "557058:5271fe35-ce1c-4d9e-bb7c-93d777bf230d", "nickname": "Jaie Wilson"}, "author": {"display_name": "Ben Buchanan", "links": {"self": {"href": "https://api.bitbucket.org/2.0/users/%7B5881db19-c8eb-4cd0-af9b-1a5b3e378e17%7D"}, "avatar": {"href": "https://avatar-management--avatars.us-west-2.prod.public.atl-paas.net/557058:6af744d8-ea74-40ff-9fbb-c7af27dc5351/259de5c8-61ca-4d67-b7fc-41deb8e8bbe9/128"}, "html": {"href": "https://bitbucket.org/%7B5881db19-c8eb-4cd0-af9b-1a5b3e378e17%7D/"}}, "type": "user", "uuid": "{5881db19-c8eb-4cd0-af9b-1a5b3e378e17}", "account_id": "557058:6af744d8-ea74-40ff-9fbb-c7af27dc5351", "nickname": "200ok"}, "reason": "", "created_on": "2011-11-02T05:10:57.655043+00:00", "updated_on": "2011-11-02T05:23:32.012180+00:00", "closed_on": "2011-11-02T05:23:31.438428+00:00", "destination": {"branch": {"name": "master"}, "commit": {"type": "commit", "hash": "3d83e9aa790ef44d2ed02eb6708bec7b28e410d3", "date": "2011-10-27T02:59:21+00:00", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/commit/3d83e9aa790ef44d2ed02eb6708bec7b28e410d3"}, "html": {"href": "https://bitbucket.org/atlassian/aui/commits/3d83e9aa790ef44d2ed02eb6708bec7b28e410d3"}}}, "repository": {"type": "repository", "full_name": "atlassian/aui", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui"}, "html": {"href": "https://bitbucket.org/atlassian/aui"}, "avatar": {"href": "https://bytebucket.org/ravatar/%7B585074de-7b60-4fd1-81ed-e0bc7fafbda5%7D?ts=86317"}}, "name": "aui", "uuid": "{585074de-7b60-4fd1-81ed-e0bc7fafbda5}"}}, "source": {"branch": {"name": "master", "links": {}}, "commit": null, "repository": null}, "reviewers": [], "participants": [{"type": "participant", "user": {"display_name": "Jason Berry", "links": {"self": {"href": "https://api.bitbucket.org/2.0/users/%7B2a7482f5-ccf1-4c98-89f2-4b5c8434601d%7D"}, "avatar": {"href": "https://secure.gravatar.com/avatar/5664c95b41e5fc913d9c53861e6ea4c6?d=https%3A%2F%2Favatar-management--avatars.us-west-2.prod.public.atl-paas.net%2Finitials%2FJB-6.png"}, "html": {"href": "https://bitbucket.org/%7B2a7482f5-ccf1-4c98-89f2-4b5c8434601d%7D/"}}, "type": "user", "uuid": "{2a7482f5-ccf1-4c98-89f2-4b5c8434601d}", "account_id": "557058:d42d7454-f9de-4bdf-9584-9abfc1c8102f", "nickname": "Jason Berry"}, "role": "PARTICIPANT", "approved": false, "state": null, "participated_on": "2011-11-03T02:54:51.194329+00:00"}, {"type": "participant", "user": {"display_name": "Ben Buchanan", "links": {"self": {"href": "https://api.bitbucket.org/2.0/users/%7B5881db19-c8eb-4cd0-af9b-1a5b3e378e17%7D"}, "avatar": {"href": "https://avatar-management--avatars.us-west-2.prod.public.atl-paas.net/557058:6af744d8-ea74-40ff-9fbb-c7af27dc5351/259de5c8-61ca-4d67-b7fc-41deb8e8bbe9/128"}, "html": {"href": "https://bitbucket.org/%7B5881db19-c8eb-4cd0-af9b-1a5b3e378e17%7D/"}}, "type": "user", "uuid": "{5881db19-c8eb-4cd0-af9b-1a5b3e378e17}", "account_id": "557058:6af744d8-ea74-40ff-9fbb-c7af27dc5351", "nickname": "200ok"}, "role": "PARTICIPANT", "approved": false, "state": null, "participated_on": "2011-11-03T02:36:54.859631+00:00"}], "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1"}, "commits": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/commits"}, "approve": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/approve"}, "request-changes": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/request-changes"}, "diff": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/diff/atlassian/aui:108d70a532dd%0D3d83e9aa790e?from_pullrequest_id=1&exclude_files=8d74170f-e08f-41d8-8d65-ce063fa86348"}, "diffstat": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/diffstat/atlassian/aui:108d70a532dd%0D3d83e9aa790e?from_pullrequest_id=1&exclude_files=8d74170f-e08f-41d8-8d65-ce063fa86348"}, "comments": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments"}, "activity": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/activity"}, "merge": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/merge"}, "decline": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/decline"}, "statuses": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/statuses"}, "mergeability_checks": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/mergeability/checks"}}, "properties": {}, "summary": {"type": "rendered", "raw": "As discussed at FERM. Will put this on master first then backport as required.", "markup": "markdown", "html": "
As discussed at FERM. Will put this on master first then backport as required.
"}, "merge_in_progress": null, "ai_contribution": false, "queued": false, "queue_in_progress": null}], "pagelen": 1, "size": 5474, "page": 1, "next": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests?fields=%2Bvalues.participants%2C%2Bvalues.%2A.commit.date%2C%2Bvalues.merge_commit.date&page=2&pagelen=1&sort=created_on&state=OPEN&state=MERGED&state=DECLINED&state=SUPERSEDED"} \ No newline at end of file diff --git a/services/migrations/_mock_data/TestBitbucketDownloadRepo/GET_%2F2.0%2Frepositories%2Fatlassian%2Faui%2Fpullrequests%2F1%2Fcomments b/services/migrations/_mock_data/TestBitbucketDownloadRepo/GET_%2F2.0%2Frepositories%2Fatlassian%2Faui%2Fpullrequests%2F1%2Fcomments new file mode 100644 index 00000000000..cd1f64fc8f3 --- /dev/null +++ b/services/migrations/_mock_data/TestBitbucketDownloadRepo/GET_%2F2.0%2Frepositories%2Fatlassian%2Faui%2Fpullrequests%2F1%2Fcomments @@ -0,0 +1,35 @@ +Age: 0 +Atl-Request-Id: 754633c8-d49c-413e-a9dd-b6a319700346 +Atl-Traceid: 754633c8d49c413ea9ddb6a319700346 +Cache-Control: max-age=900 +Content-Type: application/json; charset=utf-8 +Server-Timing: cdn-upstream-layer;desc="EDGE",cdn-upstream-dns;dur=0,cdn-upstream-connect;dur=0,cdn-upstream-fbl;dur=863,atl-edge;dur=757,atl-edge-internal;dur=8,atl-edge-upstream;dur=749,atl-edge-pop;desc="aws-us-east-1",cdn-cache-miss,cdn-pop;desc="VIE50-P1",cdn-rid;desc="iJzf36UVx1dY6Cd0i0iUYl5PS470YK0TolLZy8YYoTl7QCLDqcc-Lw==",cdn-downstream-fbl;dur=866 +Strict-Transport-Security: max-age=63072000; includeSubDomains; preload +Vary: Authorization, origin, Accept-Encoding +Via: 1.1 9127bf22c332a88edd7d5939b5870d1e.cloudfront.net (CloudFront) +X-Accepted-Oauth-Scopes: pullrequest +X-Amz-Cf-Id: iJzf36UVx1dY6Cd0i0iUYl5PS470YK0TolLZy8YYoTl7QCLDqcc-Lw== +X-Amz-Cf-Pop: VIE50-P1 +X-Asap-Succeeded: True +X-B3-Spanid: cec56d2b24e72a51 +X-B3-Traceid: 754633c8d49c413ea9ddb6a319700346 +X-Cache: Miss from cloudfront +X-Content-Type-Options: nosniff +X-Credential-Type: unauthenticated_identity +X-Dc-Location: Micros-3 +X-Envoy-Attempt-Count: 1 +X-Frame-Options: SAMEORIGIN +X-Render-Time: 0.7233684062957764 +X-Request-Count: 3456 +X-Served-By: 4525283b180c +X-Static-Version: 23055ebb54a0 +X-Usage-Input-Ops: 64 +X-Usage-Output-Ops: 48 +X-Usage-System-Time: 0.020775 +X-Usage-User-Time: 0.435677 +X-Used-Mesh: False +X-Version: 23055ebb54a0 +X-View-Name: bitbucket.apps.pullrequests.api.v20.handlers.PullRequestCommentsV20Handler +X-Xss-Protection: 1; mode=block + +{"values": [{"id": 752, "created_on": "2011-11-02T23:26:25.284238+00:00", "updated_on": "2011-11-02T23:26:25.301897+00:00", "content": {"type": "rendered", "raw": "I think we should leave this out of the layout css\n.aui-layout #header input[type='search'] {\n margin: 2px 0 0 0;\n padding: 0;\n}\nNot all products use the search field and it renders differently in different browsers. Probably something best left for the products to style.", "markup": "creole", "html": "I think we should leave this out of the layout css\n.aui-layout #header input[type='search'] {\n margin: 2px 0 0 0;\n padding: 0;\n}\nNot all products use the search field and it renders differently in different browsers. Probably something best left for the products to style.
\n"}, "user": {"display_name": "Sean Curtis", "links": {"self": {"href": "https://api.bitbucket.org/2.0/users/%7Bdf80b26c-31cb-4dc7-826a-443fdce4b6e7%7D"}, "avatar": {"href": "https://avatar-management--avatars.us-west-2.prod.public.atl-paas.net/initials/SC-0.png"}, "html": {"href": "https://bitbucket.org/%7Bdf80b26c-31cb-4dc7-826a-443fdce4b6e7%7D/"}}, "type": "user", "uuid": "{df80b26c-31cb-4dc7-826a-443fdce4b6e7}", "account_id": "557057:abdc4f56-58c1-44db-a647-4531f709c366", "nickname": "Sean Curtis"}, "deleted": false, "pending": false, "type": "pullrequest_comment", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/752"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-752"}}, "pullrequest": {"type": "pullrequest", "id": 1, "title": "Heading size change and split typography to separate resource", "draft": false, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1"}}, "queued": false}}, {"id": 753, "created_on": "2011-11-02T23:29:27.650347+00:00", "updated_on": "2011-11-02T23:29:27.666716+00:00", "content": {"type": "rendered", "raw": "We don't have a search in Bamboo so it didn't bother me.", "markup": "creole", "html": "We don't have a search in Bamboo so it didn't bother me.
\n"}, "user": {"display_name": "Jason Berry", "links": {"self": {"href": "https://api.bitbucket.org/2.0/users/%7B2a7482f5-ccf1-4c98-89f2-4b5c8434601d%7D"}, "avatar": {"href": "https://secure.gravatar.com/avatar/5664c95b41e5fc913d9c53861e6ea4c6?d=https%3A%2F%2Favatar-management--avatars.us-west-2.prod.public.atl-paas.net%2Finitials%2FJB-6.png"}, "html": {"href": "https://bitbucket.org/%7B2a7482f5-ccf1-4c98-89f2-4b5c8434601d%7D/"}}, "type": "user", "uuid": "{2a7482f5-ccf1-4c98-89f2-4b5c8434601d}", "account_id": "557058:d42d7454-f9de-4bdf-9584-9abfc1c8102f", "nickname": "Jason Berry"}, "deleted": false, "parent": {"id": 752, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/752"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-752"}}}, "pending": false, "type": "pullrequest_comment", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/753"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-753"}}, "pullrequest": {"type": "pullrequest", "id": 1, "title": "Heading size change and split typography to separate resource", "draft": false, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1"}}, "queued": false}}, {"id": 754, "created_on": "2011-11-02T23:29:35.097456+00:00", "updated_on": "2011-11-02T23:29:35.114656+00:00", "content": {"type": "rendered", "raw": "#content > header h2 is not prefixed with .aui-layout", "markup": "creole", "html": "I'm cool with these changes.
\nEdit: Thought we were just commenting on the changeset, not everything else too. Adding other comments.
\n"}, "user": {"display_name": "Jason Berry", "links": {"self": {"href": "https://api.bitbucket.org/2.0/users/%7B2a7482f5-ccf1-4c98-89f2-4b5c8434601d%7D"}, "avatar": {"href": "https://secure.gravatar.com/avatar/5664c95b41e5fc913d9c53861e6ea4c6?d=https%3A%2F%2Favatar-management--avatars.us-west-2.prod.public.atl-paas.net%2Finitials%2FJB-6.png"}, "html": {"href": "https://bitbucket.org/%7B2a7482f5-ccf1-4c98-89f2-4b5c8434601d%7D/"}}, "type": "user", "uuid": "{2a7482f5-ccf1-4c98-89f2-4b5c8434601d}", "account_id": "557058:d42d7454-f9de-4bdf-9584-9abfc1c8102f", "nickname": "Jason Berry"}, "deleted": false, "pending": false, "type": "pullrequest_comment", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/755"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-755"}}, "pullrequest": {"type": "pullrequest", "id": 1, "title": "Heading size change and split typography to separate resource", "draft": false, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1"}}, "queued": false}}, {"id": 756, "created_on": "2011-11-02T23:30:32.800786+00:00", "updated_on": "2011-11-02T23:34:46.589784+00:00", "content": {"type": "rendered", "raw": "Actually probably best to remove lines 69-80 of layout unless we want to push the content-body/container pattern into aui", "markup": "creole", "html": "Actually probably best to remove lines 69-80 of layout unless we want to push the content-body/container pattern into aui
\n"}, "user": {"display_name": "Sean Curtis", "links": {"self": {"href": "https://api.bitbucket.org/2.0/users/%7Bdf80b26c-31cb-4dc7-826a-443fdce4b6e7%7D"}, "avatar": {"href": "https://avatar-management--avatars.us-west-2.prod.public.atl-paas.net/initials/SC-0.png"}, "html": {"href": "https://bitbucket.org/%7Bdf80b26c-31cb-4dc7-826a-443fdce4b6e7%7D/"}}, "type": "user", "uuid": "{df80b26c-31cb-4dc7-826a-443fdce4b6e7}", "account_id": "557057:abdc4f56-58c1-44db-a647-4531f709c366", "nickname": "Sean Curtis"}, "deleted": false, "pending": false, "type": "pullrequest_comment", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/756"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-756"}}, "pullrequest": {"type": "pullrequest", "id": 1, "title": "Heading size change and split typography to separate resource", "draft": false, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1"}}, "queued": false}}, {"id": 757, "created_on": "2011-11-02T23:32:32.578051+00:00", "updated_on": "2011-11-02T23:32:32.603691+00:00", "content": {"type": "rendered", "raw": "Good catch.", "markup": "creole", "html": "Good catch.
\n"}, "user": {"display_name": "Jason Berry", "links": {"self": {"href": "https://api.bitbucket.org/2.0/users/%7B2a7482f5-ccf1-4c98-89f2-4b5c8434601d%7D"}, "avatar": {"href": "https://secure.gravatar.com/avatar/5664c95b41e5fc913d9c53861e6ea4c6?d=https%3A%2F%2Favatar-management--avatars.us-west-2.prod.public.atl-paas.net%2Finitials%2FJB-6.png"}, "html": {"href": "https://bitbucket.org/%7B2a7482f5-ccf1-4c98-89f2-4b5c8434601d%7D/"}}, "type": "user", "uuid": "{2a7482f5-ccf1-4c98-89f2-4b5c8434601d}", "account_id": "557058:d42d7454-f9de-4bdf-9584-9abfc1c8102f", "nickname": "Jason Berry"}, "deleted": false, "parent": {"id": 754, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/754"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-754"}}}, "pending": false, "type": "pullrequest_comment", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/757"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-757"}}, "pullrequest": {"type": "pullrequest", "id": 1, "title": "Heading size change and split typography to separate resource", "draft": false, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1"}}, "queued": false}}, {"id": 758, "created_on": "2011-11-02T23:32:59.736009+00:00", "updated_on": "2011-11-02T23:32:59.763220+00:00", "content": {"type": "rendered", "raw": "Is that a JIRA-only thing?", "markup": "creole", "html": "Is that a JIRA-only thing?
\n"}, "user": {"display_name": "Jason Berry", "links": {"self": {"href": "https://api.bitbucket.org/2.0/users/%7B2a7482f5-ccf1-4c98-89f2-4b5c8434601d%7D"}, "avatar": {"href": "https://secure.gravatar.com/avatar/5664c95b41e5fc913d9c53861e6ea4c6?d=https%3A%2F%2Favatar-management--avatars.us-west-2.prod.public.atl-paas.net%2Finitials%2FJB-6.png"}, "html": {"href": "https://bitbucket.org/%7B2a7482f5-ccf1-4c98-89f2-4b5c8434601d%7D/"}}, "type": "user", "uuid": "{2a7482f5-ccf1-4c98-89f2-4b5c8434601d}", "account_id": "557058:d42d7454-f9de-4bdf-9584-9abfc1c8102f", "nickname": "Jason Berry"}, "deleted": false, "parent": {"id": 756, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/756"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-756"}}}, "pending": false, "type": "pullrequest_comment", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/758"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-758"}}, "pullrequest": {"type": "pullrequest", "id": 1, "title": "Heading size change and split typography to separate resource", "draft": false, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1"}}, "queued": false}}, {"id": 759, "created_on": "2011-11-02T23:34:20.820273+00:00", "updated_on": "2011-11-02T23:34:38.887386+00:00", "content": {"type": "rendered", "raw": "Add line breaks to the comma-separated selectors on line 200 of layout", "markup": "creole", "html": "Add line breaks to the comma-separated selectors on line 200 of layout
\n"}, "user": {"display_name": "Sean Curtis", "links": {"self": {"href": "https://api.bitbucket.org/2.0/users/%7Bdf80b26c-31cb-4dc7-826a-443fdce4b6e7%7D"}, "avatar": {"href": "https://avatar-management--avatars.us-west-2.prod.public.atl-paas.net/initials/SC-0.png"}, "html": {"href": "https://bitbucket.org/%7Bdf80b26c-31cb-4dc7-826a-443fdce4b6e7%7D/"}}, "type": "user", "uuid": "{df80b26c-31cb-4dc7-826a-443fdce4b6e7}", "account_id": "557057:abdc4f56-58c1-44db-a647-4531f709c366", "nickname": "Sean Curtis"}, "deleted": false, "pending": false, "type": "pullrequest_comment", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/759"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-759"}}, "pullrequest": {"type": "pullrequest", "id": 1, "title": "Heading size change and split typography to separate resource", "draft": false, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1"}}, "queued": false}}, {"id": 760, "created_on": "2011-11-02T23:36:34.206229+00:00", "updated_on": "2011-11-02T23:40:28.289157+00:00", "content": {"type": "rendered", "raw": "Selectors on the following lines can be merged:\n213/248\n217/252\n227/273\n231/277\n221/235/256/281", "markup": "creole", "html": "Selectors on the following lines can be merged:\n213/248\n217/252\n227/273\n231/277\n221/235/256/281
\n"}, "user": {"display_name": "Sean Curtis", "links": {"self": {"href": "https://api.bitbucket.org/2.0/users/%7Bdf80b26c-31cb-4dc7-826a-443fdce4b6e7%7D"}, "avatar": {"href": "https://avatar-management--avatars.us-west-2.prod.public.atl-paas.net/initials/SC-0.png"}, "html": {"href": "https://bitbucket.org/%7Bdf80b26c-31cb-4dc7-826a-443fdce4b6e7%7D/"}}, "type": "user", "uuid": "{df80b26c-31cb-4dc7-826a-443fdce4b6e7}", "account_id": "557057:abdc4f56-58c1-44db-a647-4531f709c366", "nickname": "Sean Curtis"}, "deleted": false, "pending": false, "type": "pullrequest_comment", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/760"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-760"}}, "pullrequest": {"type": "pullrequest", "id": 1, "title": "Heading size change and split typography to separate resource", "draft": false, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1"}}, "queued": false}}, {"id": 761, "created_on": "2011-11-02T23:42:38.533879+00:00", "updated_on": "2011-11-02T23:42:38.563418+00:00", "content": {"type": "rendered", "raw": "Line 351 is unnecessary - already included above on line 171", "markup": "creole", "html": "Line 351 is unnecessary - already included above on line 171
\n"}, "user": {"display_name": "Sean Curtis", "links": {"self": {"href": "https://api.bitbucket.org/2.0/users/%7Bdf80b26c-31cb-4dc7-826a-443fdce4b6e7%7D"}, "avatar": {"href": "https://avatar-management--avatars.us-west-2.prod.public.atl-paas.net/initials/SC-0.png"}, "html": {"href": "https://bitbucket.org/%7Bdf80b26c-31cb-4dc7-826a-443fdce4b6e7%7D/"}}, "type": "user", "uuid": "{df80b26c-31cb-4dc7-826a-443fdce4b6e7}", "account_id": "557057:abdc4f56-58c1-44db-a647-4531f709c366", "nickname": "Sean Curtis"}, "deleted": false, "pending": false, "type": "pullrequest_comment", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/761"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-761"}}, "pullrequest": {"type": "pullrequest", "id": 1, "title": "Heading size change and split typography to separate resource", "draft": false, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1"}}, "queued": false}}, {"id": 762, "created_on": "2011-11-02T23:43:46.838639+00:00", "updated_on": "2011-11-02T23:45:04.824380+00:00", "content": {"type": "rendered", "raw": "While we're commenting wildly, here are some things I needed to add/override in Bamboo:\n{{{\n#!css\n\n.aui-theme-default #header .local .secondary > ul > li > a:hover {\n background: #fff;\n color: #333;\n}\n.aui-theme-default #header .local .secondary > ul > li.selected,\n.aui-theme-default #header .local .secondary > ul > li.selected a {\n background: #f0f0f0;\n color: #333;\n}\n.aui-theme-default #header .aui-dropdown {\n min-width: 80px;\n}\n.aui-theme-default #header .aui-dropdown .item-link {\n color: #333;\n display: block;\n padding: 0.4em 8px;\n text-decoration: none;\n}\n.aui-theme-default #header .global .secondary > ul {\n padding-top: 2px;\n}\n.aui-theme-default #header .global .secondary > ul > li > .aui-dd-trigger {\n cursor: pointer;\n display: block;\n padding: 4px;\n white-space: nowrap;\n}\n.aui-theme-default #header .global .secondary > ul > li.active > .aui-dd-trigger,\n.aui-theme-default #header .global .secondary > ul > li > .aui-dd-trigger:hover {\n background: #326ca6;\n color: #fff;\n}\n\n}}}", "markup": "creole", "html": "While we're commenting wildly, here are some things I needed to add/override in Bamboo:
\n.aui-theme-default #header .local .secondary > ul > li > a:hover {\n background: #fff;\n color: #333;\n}\n.aui-theme-default #header .local .secondary > ul > li.selected,\n.aui-theme-default #header .local .secondary > ul > li.selected a {\n background: #f0f0f0;\n color: #333;\n}\n.aui-theme-default #header .aui-dropdown {\n min-width: 80px;\n}\n.aui-theme-default #header .aui-dropdown .item-link {\n color: #333;\n display: block;\n padding: 0.4em 8px;\n text-decoration: none;\n}\n.aui-theme-default #header .global .secondary > ul {\n padding-top: 2px;\n}\n.aui-theme-default #header .global .secondary > ul > li > .aui-dd-trigger {\n cursor: pointer;\n display: block;\n padding: 4px;\n white-space: nowrap;\n}\n.aui-theme-default #header .global .secondary > ul > li.active > .aui-dd-trigger,\n.aui-theme-default #header .global .secondary > ul > li > .aui-dd-trigger:hover {\n background: #326ca6;\n color: #fff;\n}\n
....yeah, I miss Crucible already.
\n"}, "user": {"display_name": "Ben Buchanan", "links": {"self": {"href": "https://api.bitbucket.org/2.0/users/%7B5881db19-c8eb-4cd0-af9b-1a5b3e378e17%7D"}, "avatar": {"href": "https://avatar-management--avatars.us-west-2.prod.public.atl-paas.net/557058:6af744d8-ea74-40ff-9fbb-c7af27dc5351/259de5c8-61ca-4d67-b7fc-41deb8e8bbe9/128"}, "html": {"href": "https://bitbucket.org/%7B5881db19-c8eb-4cd0-af9b-1a5b3e378e17%7D/"}}, "type": "user", "uuid": "{5881db19-c8eb-4cd0-af9b-1a5b3e378e17}", "account_id": "557058:6af744d8-ea74-40ff-9fbb-c7af27dc5351", "nickname": "200ok"}, "deleted": false, "pending": false, "type": "pullrequest_comment", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/764"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-764"}}, "pullrequest": {"type": "pullrequest", "id": 1, "title": "Heading size change and split typography to separate resource", "draft": false, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1"}}, "queued": false}}, {"id": 765, "created_on": "2011-11-03T00:23:46.862166+00:00", "updated_on": "2011-11-03T00:23:56.624317+00:00", "content": {"type": "rendered", "raw": "That << issue 326 >> crap shouldn't be there, but I couldn't figure out how to stop bitbucket screwing with my hex colours.", "markup": "creole", "html": "That << issue 326 >> crap shouldn't be there, but I couldn't figure out how to stop bitbucket screwing with my hex colours.
\n"}, "user": {"display_name": "Jason Berry", "links": {"self": {"href": "https://api.bitbucket.org/2.0/users/%7B2a7482f5-ccf1-4c98-89f2-4b5c8434601d%7D"}, "avatar": {"href": "https://secure.gravatar.com/avatar/5664c95b41e5fc913d9c53861e6ea4c6?d=https%3A%2F%2Favatar-management--avatars.us-west-2.prod.public.atl-paas.net%2Finitials%2FJB-6.png"}, "html": {"href": "https://bitbucket.org/%7B2a7482f5-ccf1-4c98-89f2-4b5c8434601d%7D/"}}, "type": "user", "uuid": "{2a7482f5-ccf1-4c98-89f2-4b5c8434601d}", "account_id": "557058:d42d7454-f9de-4bdf-9584-9abfc1c8102f", "nickname": "Jason Berry"}, "deleted": false, "parent": {"id": 762, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/762"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-762"}}}, "pending": false, "type": "pullrequest_comment", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/765"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-765"}}, "pullrequest": {"type": "pullrequest", "id": 1, "title": "Heading size change and split typography to separate resource", "draft": false, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1"}}, "queued": false}}, {"id": 766, "created_on": "2011-11-03T02:26:01.663708+00:00", "updated_on": "2011-11-03T02:26:01.673821+00:00", "content": {"type": "rendered", "raw": "It's a bit random, will remove.", "markup": "creole", "html": "It's a bit random, will remove.
\n"}, "user": {"display_name": "Ben Buchanan", "links": {"self": {"href": "https://api.bitbucket.org/2.0/users/%7B5881db19-c8eb-4cd0-af9b-1a5b3e378e17%7D"}, "avatar": {"href": "https://avatar-management--avatars.us-west-2.prod.public.atl-paas.net/557058:6af744d8-ea74-40ff-9fbb-c7af27dc5351/259de5c8-61ca-4d67-b7fc-41deb8e8bbe9/128"}, "html": {"href": "https://bitbucket.org/%7B5881db19-c8eb-4cd0-af9b-1a5b3e378e17%7D/"}}, "type": "user", "uuid": "{5881db19-c8eb-4cd0-af9b-1a5b3e378e17}", "account_id": "557058:6af744d8-ea74-40ff-9fbb-c7af27dc5351", "nickname": "200ok"}, "deleted": false, "parent": {"id": 752, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/752"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-752"}}}, "pending": false, "type": "pullrequest_comment", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/766"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-766"}}, "pullrequest": {"type": "pullrequest", "id": 1, "title": "Heading size change and split typography to separate resource", "draft": false, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1"}}, "queued": false}}, {"id": 767, "created_on": "2011-11-03T02:26:13.154822+00:00", "updated_on": "2011-11-03T02:26:13.163969+00:00", "content": {"type": "rendered", "raw": "fixed", "markup": "creole", "html": "fixed
\n"}, "user": {"display_name": "Ben Buchanan", "links": {"self": {"href": "https://api.bitbucket.org/2.0/users/%7B5881db19-c8eb-4cd0-af9b-1a5b3e378e17%7D"}, "avatar": {"href": "https://avatar-management--avatars.us-west-2.prod.public.atl-paas.net/557058:6af744d8-ea74-40ff-9fbb-c7af27dc5351/259de5c8-61ca-4d67-b7fc-41deb8e8bbe9/128"}, "html": {"href": "https://bitbucket.org/%7B5881db19-c8eb-4cd0-af9b-1a5b3e378e17%7D/"}}, "type": "user", "uuid": "{5881db19-c8eb-4cd0-af9b-1a5b3e378e17}", "account_id": "557058:6af744d8-ea74-40ff-9fbb-c7af27dc5351", "nickname": "200ok"}, "deleted": false, "parent": {"id": 754, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/754"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-754"}}}, "pending": false, "type": "pullrequest_comment", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/767"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-767"}}, "pullrequest": {"type": "pullrequest", "id": 1, "title": "Heading size change and split typography to separate resource", "draft": false, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1"}}, "queued": false}}, {"id": 768, "created_on": "2011-11-03T02:30:04.262166+00:00", "updated_on": "2011-11-03T02:30:04.272712+00:00", "content": {"type": "rendered", "raw": "Did intend to just do the changeset, but realistically the actual goal is to get this component improved for better usage.", "markup": "creole", "html": "Did intend to just do the changeset, but realistically the actual goal is to get this component improved for better usage.
\n"}, "user": {"display_name": "Ben Buchanan", "links": {"self": {"href": "https://api.bitbucket.org/2.0/users/%7B5881db19-c8eb-4cd0-af9b-1a5b3e378e17%7D"}, "avatar": {"href": "https://avatar-management--avatars.us-west-2.prod.public.atl-paas.net/557058:6af744d8-ea74-40ff-9fbb-c7af27dc5351/259de5c8-61ca-4d67-b7fc-41deb8e8bbe9/128"}, "html": {"href": "https://bitbucket.org/%7B5881db19-c8eb-4cd0-af9b-1a5b3e378e17%7D/"}}, "type": "user", "uuid": "{5881db19-c8eb-4cd0-af9b-1a5b3e378e17}", "account_id": "557058:6af744d8-ea74-40ff-9fbb-c7af27dc5351", "nickname": "200ok"}, "deleted": false, "parent": {"id": 755, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/755"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-755"}}}, "pending": false, "type": "pullrequest_comment", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/768"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-768"}}, "pullrequest": {"type": "pullrequest", "id": 1, "title": "Heading size change and split typography to separate resource", "draft": false, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1"}}, "queued": false}}, {"id": 769, "created_on": "2011-11-03T02:30:50.938714+00:00", "updated_on": "2011-11-03T02:30:50.947724+00:00", "content": {"type": "rendered", "raw": "yeah I'm already screwed here, decoupled comments pretty much guarantee PRs can't be reviews... :)", "markup": "creole", "html": "yeah I'm already screwed here, decoupled comments pretty much guarantee PRs can't be reviews... :)
\n"}, "user": {"display_name": "Ben Buchanan", "links": {"self": {"href": "https://api.bitbucket.org/2.0/users/%7B5881db19-c8eb-4cd0-af9b-1a5b3e378e17%7D"}, "avatar": {"href": "https://avatar-management--avatars.us-west-2.prod.public.atl-paas.net/557058:6af744d8-ea74-40ff-9fbb-c7af27dc5351/259de5c8-61ca-4d67-b7fc-41deb8e8bbe9/128"}, "html": {"href": "https://bitbucket.org/%7B5881db19-c8eb-4cd0-af9b-1a5b3e378e17%7D/"}}, "type": "user", "uuid": "{5881db19-c8eb-4cd0-af9b-1a5b3e378e17}", "account_id": "557058:6af744d8-ea74-40ff-9fbb-c7af27dc5351", "nickname": "200ok"}, "deleted": false, "parent": {"id": 761, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/761"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-761"}}}, "pending": false, "type": "pullrequest_comment", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/769"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-769"}}, "pullrequest": {"type": "pullrequest", "id": 1, "title": "Heading size change and split typography to separate resource", "draft": false, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1"}}, "queued": false}}, {"id": 770, "created_on": "2011-11-03T02:34:01.708172+00:00", "updated_on": "2011-11-03T02:34:01.717375+00:00", "content": {"type": "rendered", "raw": "would you prefer to update or remove these styles from aui?", "markup": "creole", "html": "would you prefer to update or remove these styles from aui?
\n"}, "user": {"display_name": "Ben Buchanan", "links": {"self": {"href": "https://api.bitbucket.org/2.0/users/%7B5881db19-c8eb-4cd0-af9b-1a5b3e378e17%7D"}, "avatar": {"href": "https://avatar-management--avatars.us-west-2.prod.public.atl-paas.net/557058:6af744d8-ea74-40ff-9fbb-c7af27dc5351/259de5c8-61ca-4d67-b7fc-41deb8e8bbe9/128"}, "html": {"href": "https://bitbucket.org/%7B5881db19-c8eb-4cd0-af9b-1a5b3e378e17%7D/"}}, "type": "user", "uuid": "{5881db19-c8eb-4cd0-af9b-1a5b3e378e17}", "account_id": "557058:6af744d8-ea74-40ff-9fbb-c7af27dc5351", "nickname": "200ok"}, "deleted": false, "parent": {"id": 762, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/762"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-762"}}}, "pending": false, "type": "pullrequest_comment", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/770"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-770"}}, "pullrequest": {"type": "pullrequest", "id": 1, "title": "Heading size change and split typography to separate resource", "draft": false, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1"}}, "queued": false}}, {"id": 771, "created_on": "2011-11-03T02:36:35.520198+00:00", "updated_on": "2011-11-03T02:36:35.532629+00:00", "content": {"type": "rendered", "raw": "done", "markup": "creole", "html": "done
\n"}, "user": {"display_name": "Ben Buchanan", "links": {"self": {"href": "https://api.bitbucket.org/2.0/users/%7B5881db19-c8eb-4cd0-af9b-1a5b3e378e17%7D"}, "avatar": {"href": "https://avatar-management--avatars.us-west-2.prod.public.atl-paas.net/557058:6af744d8-ea74-40ff-9fbb-c7af27dc5351/259de5c8-61ca-4d67-b7fc-41deb8e8bbe9/128"}, "html": {"href": "https://bitbucket.org/%7B5881db19-c8eb-4cd0-af9b-1a5b3e378e17%7D/"}}, "type": "user", "uuid": "{5881db19-c8eb-4cd0-af9b-1a5b3e378e17}", "account_id": "557058:6af744d8-ea74-40ff-9fbb-c7af27dc5351", "nickname": "200ok"}, "deleted": false, "parent": {"id": 760, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/760"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-760"}}}, "pending": false, "type": "pullrequest_comment", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/771"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-771"}}, "pullrequest": {"type": "pullrequest", "id": 1, "title": "Heading size change and split typography to separate resource", "draft": false, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1"}}, "queued": false}}, {"id": 772, "created_on": "2011-11-03T02:36:43.794399+00:00", "updated_on": "2011-11-03T02:36:43.805188+00:00", "content": {"type": "rendered", "raw": "ok done", "markup": "creole", "html": "ok done
\n"}, "user": {"display_name": "Ben Buchanan", "links": {"self": {"href": "https://api.bitbucket.org/2.0/users/%7B5881db19-c8eb-4cd0-af9b-1a5b3e378e17%7D"}, "avatar": {"href": "https://avatar-management--avatars.us-west-2.prod.public.atl-paas.net/557058:6af744d8-ea74-40ff-9fbb-c7af27dc5351/259de5c8-61ca-4d67-b7fc-41deb8e8bbe9/128"}, "html": {"href": "https://bitbucket.org/%7B5881db19-c8eb-4cd0-af9b-1a5b3e378e17%7D/"}}, "type": "user", "uuid": "{5881db19-c8eb-4cd0-af9b-1a5b3e378e17}", "account_id": "557058:6af744d8-ea74-40ff-9fbb-c7af27dc5351", "nickname": "200ok"}, "deleted": false, "parent": {"id": 761, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/761"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-761"}}}, "pending": false, "type": "pullrequest_comment", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/772"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-772"}}, "pullrequest": {"type": "pullrequest", "id": 1, "title": "Heading size change and split typography to separate resource", "draft": false, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1"}}, "queued": false}}, {"id": 773, "created_on": "2011-11-03T02:36:54.849374+00:00", "updated_on": "2011-11-03T02:36:54.859631+00:00", "content": {"type": "rendered", "raw": "presuming you meant hte headings, done", "markup": "creole", "html": "presuming you meant hte headings, done
\n"}, "user": {"display_name": "Ben Buchanan", "links": {"self": {"href": "https://api.bitbucket.org/2.0/users/%7B5881db19-c8eb-4cd0-af9b-1a5b3e378e17%7D"}, "avatar": {"href": "https://avatar-management--avatars.us-west-2.prod.public.atl-paas.net/557058:6af744d8-ea74-40ff-9fbb-c7af27dc5351/259de5c8-61ca-4d67-b7fc-41deb8e8bbe9/128"}, "html": {"href": "https://bitbucket.org/%7B5881db19-c8eb-4cd0-af9b-1a5b3e378e17%7D/"}}, "type": "user", "uuid": "{5881db19-c8eb-4cd0-af9b-1a5b3e378e17}", "account_id": "557058:6af744d8-ea74-40ff-9fbb-c7af27dc5351", "nickname": "200ok"}, "deleted": false, "parent": {"id": 759, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/759"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-759"}}}, "pending": false, "type": "pullrequest_comment", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/773"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-773"}}, "pullrequest": {"type": "pullrequest", "id": 1, "title": "Heading size change and split typography to separate resource", "draft": false, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1"}}, "queued": false}}, {"id": 774, "created_on": "2011-11-03T02:54:51.178808+00:00", "updated_on": "2011-11-03T02:54:51.194329+00:00", "content": {"type": "rendered", "raw": "I'd probably like to add them (or something like it) to AUI. They should be fairly standard cross-product. The only reason they weren't in there is because JIRA has a custom dropdown.\n\nCertainly the \"#header .aui-dropdown\" and \".global .secondary\" stuff should consider being added - it's the AUI dropdown at the top-right for the user. The \".local .secondary\" stuff maybe not so much.", "markup": "creole", "html": "I'd probably like to add them (or something like it) to AUI. They should be fairly standard cross-product. The only reason they weren't in there is because JIRA has a custom dropdown.
\nCertainly the \"#header .aui-dropdown\" and \".global .secondary\" stuff should consider being added - it's the AUI dropdown at the top-right for the user. The \".local .secondary\" stuff maybe not so much.
\n"}, "user": {"display_name": "Jason Berry", "links": {"self": {"href": "https://api.bitbucket.org/2.0/users/%7B2a7482f5-ccf1-4c98-89f2-4b5c8434601d%7D"}, "avatar": {"href": "https://secure.gravatar.com/avatar/5664c95b41e5fc913d9c53861e6ea4c6?d=https%3A%2F%2Favatar-management--avatars.us-west-2.prod.public.atl-paas.net%2Finitials%2FJB-6.png"}, "html": {"href": "https://bitbucket.org/%7B2a7482f5-ccf1-4c98-89f2-4b5c8434601d%7D/"}}, "type": "user", "uuid": "{2a7482f5-ccf1-4c98-89f2-4b5c8434601d}", "account_id": "557058:d42d7454-f9de-4bdf-9584-9abfc1c8102f", "nickname": "Jason Berry"}, "deleted": false, "parent": {"id": 770, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/770"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-770"}}}, "pending": false, "type": "pullrequest_comment", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/774"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-774"}}, "pullrequest": {"type": "pullrequest", "id": 1, "title": "Heading size change and split typography to separate resource", "draft": false, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1"}}, "queued": false}}, {"id": 775, "created_on": "2011-11-03T04:21:32.272584+00:00", "updated_on": "2011-11-03T04:21:32.293398+00:00", "content": {"type": "rendered", "raw": "Well I'm happy for other products to use it but if so we'd probably have to aui-fy that pattern. It'd be a nice opt-in thing for people to use if they wanted...", "markup": "creole", "html": "Well I'm happy for other products to use it but if so we'd probably have to aui-fy that pattern. It'd be a nice opt-in thing for people to use if they wanted...
\n"}, "user": {"display_name": "Sean Curtis", "links": {"self": {"href": "https://api.bitbucket.org/2.0/users/%7Bdf80b26c-31cb-4dc7-826a-443fdce4b6e7%7D"}, "avatar": {"href": "https://avatar-management--avatars.us-west-2.prod.public.atl-paas.net/initials/SC-0.png"}, "html": {"href": "https://bitbucket.org/%7Bdf80b26c-31cb-4dc7-826a-443fdce4b6e7%7D/"}}, "type": "user", "uuid": "{df80b26c-31cb-4dc7-826a-443fdce4b6e7}", "account_id": "557057:abdc4f56-58c1-44db-a647-4531f709c366", "nickname": "Sean Curtis"}, "deleted": false, "parent": {"id": 758, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/758"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-758"}}}, "pending": false, "type": "pullrequest_comment", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/775"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-775"}}, "pullrequest": {"type": "pullrequest", "id": 1, "title": "Heading size change and split typography to separate resource", "draft": false, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1"}}, "queued": false}}, {"id": 776, "created_on": "2011-11-03T04:22:49.970685+00:00", "updated_on": "2011-11-03T04:22:49.996783+00:00", "content": {"type": "rendered", "raw": "I don't see the point of including the styles in this experimental css file if they're not aui sanctioned things. As it stands these styles will duplicate/tread on the toes of what is currently a JIRA-specific pattern.", "markup": "creole", "html": "I don't see the point of including the styles in this experimental css file if they're not aui sanctioned things. As it stands these styles will duplicate/tread on the toes of what is currently a JIRA-specific pattern.
\n"}, "user": {"display_name": "Sean Curtis", "links": {"self": {"href": "https://api.bitbucket.org/2.0/users/%7Bdf80b26c-31cb-4dc7-826a-443fdce4b6e7%7D"}, "avatar": {"href": "https://avatar-management--avatars.us-west-2.prod.public.atl-paas.net/initials/SC-0.png"}, "html": {"href": "https://bitbucket.org/%7Bdf80b26c-31cb-4dc7-826a-443fdce4b6e7%7D/"}}, "type": "user", "uuid": "{df80b26c-31cb-4dc7-826a-443fdce4b6e7}", "account_id": "557057:abdc4f56-58c1-44db-a647-4531f709c366", "nickname": "Sean Curtis"}, "deleted": false, "parent": {"id": 758, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/758"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-758"}}}, "pending": false, "type": "pullrequest_comment", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/776"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-776"}}, "pullrequest": {"type": "pullrequest", "id": 1, "title": "Heading size change and split typography to separate resource", "draft": false, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1"}}, "queued": false}}, {"id": 777, "created_on": "2011-11-03T04:23:26.777979+00:00", "updated_on": "2011-11-03T04:23:26.796730+00:00", "content": {"type": "rendered", "raw": "Heh sorry - should have been more explicit with which file I was commenting on. ", "markup": "creole", "html": "Heh sorry - should have been more explicit with which file I was commenting on.
\n"}, "user": {"display_name": "Sean Curtis", "links": {"self": {"href": "https://api.bitbucket.org/2.0/users/%7Bdf80b26c-31cb-4dc7-826a-443fdce4b6e7%7D"}, "avatar": {"href": "https://avatar-management--avatars.us-west-2.prod.public.atl-paas.net/initials/SC-0.png"}, "html": {"href": "https://bitbucket.org/%7Bdf80b26c-31cb-4dc7-826a-443fdce4b6e7%7D/"}}, "type": "user", "uuid": "{df80b26c-31cb-4dc7-826a-443fdce4b6e7}", "account_id": "557057:abdc4f56-58c1-44db-a647-4531f709c366", "nickname": "Sean Curtis"}, "deleted": false, "parent": {"id": 769, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/769"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-769"}}}, "pending": false, "type": "pullrequest_comment", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1/comments/777"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1/_/diff#comment-777"}}, "pullrequest": {"type": "pullrequest", "id": 1, "title": "Heading size change and split typography to separate resource", "draft": false, "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/atlassian/aui/pullrequests/1"}, "html": {"href": "https://bitbucket.org/atlassian/aui/pull-requests/1"}}, "queued": false}}], "pagelen": 100, "size": 25, "page": 1} \ No newline at end of file diff --git a/services/migrations/_mock_data/TestBitbucketDownloadRepo/GET_%2F2.0%2Frepositories%2Fgitea%2Ftest_repo b/services/migrations/_mock_data/TestBitbucketDownloadRepo/GET_%2F2.0%2Frepositories%2Fgitea%2Ftest_repo new file mode 100644 index 00000000000..d708fc08682 --- /dev/null +++ b/services/migrations/_mock_data/TestBitbucketDownloadRepo/GET_%2F2.0%2Frepositories%2Fgitea%2Ftest_repo @@ -0,0 +1,37 @@ +Age: 0 +Atl-Request-Id: 9179a08c-393b-4ef2-9b63-0202f377b154 +Atl-Traceid: 9179a08c393b4ef29b630202f377b154 +Cache-Control: max-age=900 +Content-Type: application/json; charset=utf-8 +Etag: W/"0055c235ff1216676265b36c65aa2ea4" +Server-Timing: cdn-upstream-layer;desc="EDGE",cdn-upstream-dns;dur=1,cdn-upstream-connect;dur=0,cdn-upstream-fbl;dur=218,atl-edge;dur=115,atl-edge-internal;dur=8,atl-edge-upstream;dur=107,atl-edge-pop;desc="aws-us-east-1",cdn-cache-miss,cdn-pop;desc="VIE50-P1",cdn-rid;desc="ZezuZh_FtSEXhi0VZc38GYlAyYNS_twFTfXWN25B7YXwzL80tJAUFg==",cdn-downstream-fbl;dur=222 +Strict-Transport-Security: max-age=63072000; includeSubDomains; preload +Vary: Authorization, origin +Vary: Accept-Encoding +Via: 1.1 9127bf22c332a88edd7d5939b5870d1e.cloudfront.net (CloudFront) +X-Accepted-Oauth-Scopes: repository +X-Amz-Cf-Id: ZezuZh_FtSEXhi0VZc38GYlAyYNS_twFTfXWN25B7YXwzL80tJAUFg== +X-Amz-Cf-Pop: VIE50-P1 +X-Asap-Succeeded: True +X-B3-Spanid: e5d99cd1c4db9972 +X-B3-Traceid: 9179a08c393b4ef29b630202f377b154 +X-Cache: Miss from cloudfront +X-Content-Type-Options: nosniff +X-Credential-Type: unauthenticated_identity +X-Dc-Location: Micros-3 +X-Envoy-Attempt-Count: 1 +X-Frame-Options: SAMEORIGIN +X-Render-Time: 0.08297491073608398 +X-Request-Count: 4191 +X-Served-By: b23789207f7b +X-Static-Version: 23055ebb54a0 +X-Usage-Input-Ops: 0 +X-Usage-Output-Ops: 0 +X-Usage-System-Time: 0.000423 +X-Usage-User-Time: 0.055612 +X-Used-Mesh: False +X-Version: 23055ebb54a0 +X-View-Name: bitbucket.apps.repo2.api.v20.repo.RepositoryHandler +X-Xss-Protection: 1; mode=block + +{"type": "repository", "full_name": "gitea/test_repo", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/gitea/test_repo"}, "html": {"href": "https://bitbucket.org/gitea/test_repo"}, "avatar": {"href": "https://bytebucket.org/ravatar/%7B7b764bc5-c3f3-4910-a90b-4cdc229a66b7%7D?ts=default"}, "pullrequests": {"href": "https://api.bitbucket.org/2.0/repositories/gitea/test_repo/pullrequests"}, "commits": {"href": "https://api.bitbucket.org/2.0/repositories/gitea/test_repo/commits"}, "forks": {"href": "https://api.bitbucket.org/2.0/repositories/gitea/test_repo/forks"}, "watchers": {"href": "https://api.bitbucket.org/2.0/repositories/gitea/test_repo/watchers"}, "branches": {"href": "https://api.bitbucket.org/2.0/repositories/gitea/test_repo/refs/branches"}, "tags": {"href": "https://api.bitbucket.org/2.0/repositories/gitea/test_repo/refs/tags"}, "downloads": {"href": "https://api.bitbucket.org/2.0/repositories/gitea/test_repo/downloads"}, "source": {"href": "https://api.bitbucket.org/2.0/repositories/gitea/test_repo/src"}, "clone": [{"name": "https", "href": "https://bitbucket.org/gitea/test_repo.git"}, {"name": "ssh", "href": "git@ssh.bitbucket.org:gitea/test_repo.git"}], "hooks": {"href": "https://api.bitbucket.org/2.0/repositories/gitea/test_repo/hooks"}}, "name": "test_repo", "slug": "test_repo", "description": "", "scm": "git", "website": null, "owner": {"display_name": "gitea", "links": {"self": {"href": "https://api.bitbucket.org/2.0/workspaces/%7B5e516e72-8608-4d3e-9ca4-969288daed2a%7D"}, "avatar": {"href": "https://bitbucket.org/account/gitea4/avatar/"}, "html": {"href": "https://bitbucket.org/%7B5e516e72-8608-4d3e-9ca4-969288daed2a%7D/"}}, "type": "team", "uuid": "{5e516e72-8608-4d3e-9ca4-969288daed2a}", "username": "gitea4"}, "workspace": {"type": "workspace", "uuid": "{5e516e72-8608-4d3e-9ca4-969288daed2a}", "name": "gitea", "slug": "gitea", "links": {"avatar": {"href": "https://bitbucket.org/workspaces/gitea/avatar/?ts=1791398183"}, "html": {"href": "https://bitbucket.org/gitea/"}, "self": {"href": "https://api.bitbucket.org/2.0/workspaces/gitea"}}}, "is_private": false, "project": {"type": "project", "key": "TES", "uuid": "{94fee3ab-3d66-4ba7-a36a-134aab7a1e84}", "name": "test_repo", "links": {"self": {"href": "https://api.bitbucket.org/2.0/workspaces/gitea/projects/TES"}, "html": {"href": "https://bitbucket.org/gitea/workspace/projects/TES"}, "avatar": {"href": "https://bitbucket.org/gitea/workspace/projects/TES/avatar/32?ts=1791398116"}}}, "fork_policy": "allow_forks", "created_on": "2026-10-07T18:35:17.202781+00:00", "updated_on": "2026-10-07T18:40:40.122213+00:00", "size": 3862, "language": "", "uuid": "{7b764bc5-c3f3-4910-a90b-4cdc229a66b7}", "mainbranch": {"name": "master", "type": "branch"}, "override_settings": {"default_merge_strategy": true, "branching_model": true}, "parent": null, "enforced_signed_commits": null} \ No newline at end of file diff --git a/services/migrations/_mock_data/TestBitbucketDownloadRepo/GET_%2F2.0%2Frepositories%2Fgitea%2Ftest_repo%2Fpullrequests b/services/migrations/_mock_data/TestBitbucketDownloadRepo/GET_%2F2.0%2Frepositories%2Fgitea%2Ftest_repo%2Fpullrequests new file mode 100644 index 00000000000..a402508944e --- /dev/null +++ b/services/migrations/_mock_data/TestBitbucketDownloadRepo/GET_%2F2.0%2Frepositories%2Fgitea%2Ftest_repo%2Fpullrequests @@ -0,0 +1,37 @@ +Age: 0 +Atl-Request-Id: 1ac56c02-99bf-4e23-8e43-4a6dc0ac64f2 +Atl-Traceid: 1ac56c0299bf4e238e434a6dc0ac64f2 +Cache-Control: max-age=900 +Content-Type: application/json; charset=utf-8 +Etag: W/"d1616edb0f00570d57f256a059ae2cf9" +Server-Timing: cdn-upstream-layer;desc="EDGE",cdn-upstream-dns;dur=0,cdn-upstream-connect;dur=0,cdn-upstream-fbl;dur=518,atl-edge;dur=416,atl-edge-internal;dur=8,atl-edge-upstream;dur=408,atl-edge-pop;desc="aws-us-east-1",cdn-cache-miss,cdn-pop;desc="VIE50-P1",cdn-rid;desc="wignpm5GNER8JwK555KBwCkS1LqBl5iNxmE1d4WmhjcJBL7TxNOwCg==",cdn-downstream-fbl;dur=522 +Strict-Transport-Security: max-age=63072000; includeSubDomains; preload +Vary: Authorization, origin +Vary: Accept-Encoding +Via: 1.1 9127bf22c332a88edd7d5939b5870d1e.cloudfront.net (CloudFront) +X-Accepted-Oauth-Scopes: pullrequest +X-Amz-Cf-Id: wignpm5GNER8JwK555KBwCkS1LqBl5iNxmE1d4WmhjcJBL7TxNOwCg== +X-Amz-Cf-Pop: VIE50-P1 +X-Asap-Succeeded: True +X-B3-Spanid: 0c509dea12a6a26e +X-B3-Traceid: 1ac56c0299bf4e238e434a6dc0ac64f2 +X-Cache: Miss from cloudfront +X-Content-Type-Options: nosniff +X-Credential-Type: unauthenticated_identity +X-Dc-Location: Micros-3 +X-Envoy-Attempt-Count: 1 +X-Frame-Options: SAMEORIGIN +X-Render-Time: 0.38138413429260254 +X-Request-Count: 532 +X-Served-By: e9d9f85586a3 +X-Static-Version: 23055ebb54a0 +X-Usage-Input-Ops: 24 +X-Usage-Output-Ops: 0 +X-Usage-System-Time: 0.008078 +X-Usage-User-Time: 0.140643 +X-Used-Mesh: False +X-Version: 23055ebb54a0 +X-View-Name: bitbucket.apps.pullrequests.api.v20.handlers.RepositoryPullRequestsHandler +X-Xss-Protection: 1; mode=block + +{"values": [{"comment_count": 0, "task_count": 0, "type": "pullrequest", "id": 1, "title": "Update LICENSE", "description": "do not merge this PR", "rendered": {}, "state": "OPEN", "draft": false, "merge_commit": null, "diff_type": 2, "latest_excluded_files_version": "", "close_source_branch": false, "closed_by": null, "author": {"display_name": "Lunny Xiao", "links": {"self": {"href": "https://api.bitbucket.org/2.0/users/%7B84d46ffe-e0fa-4d3c-973f-b3ce77db43f6%7D"}, "avatar": {"href": "https://secure.gravatar.com/avatar/cfb7b37d5a38d236e451a9f8e1a29fc6?d=https%3A%2F%2Favatar-management--avatars.us-west-2.prod.public.atl-paas.net%2Finitials%2FLX-1.png"}, "html": {"href": "https://bitbucket.org/%7B84d46ffe-e0fa-4d3c-973f-b3ce77db43f6%7D/"}}, "type": "user", "uuid": "{84d46ffe-e0fa-4d3c-973f-b3ce77db43f6}", "account_id": "712020:07927e50-b64a-4fc3-a57d-dcf6945b70e6", "nickname": "Lunny Xiao"}, "reason": "", "created_on": "2026-10-07T18:39:55.551762+00:00", "updated_on": "2026-10-07T18:40:40.122213+00:00", "closed_on": null, "destination": {"branch": {"name": "master"}, "commit": {"type": "commit", "hash": "c59c9b451acca9d106cc19d61d87afe3fbbb8b83", "date": "2019-11-28T08:53:41+00:00", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/gitea/test_repo/commit/c59c9b451acca9d106cc19d61d87afe3fbbb8b83"}, "html": {"href": "https://bitbucket.org/gitea/test_repo/commits/c59c9b451acca9d106cc19d61d87afe3fbbb8b83"}}}, "repository": {"type": "repository", "full_name": "gitea/test_repo", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/gitea/test_repo"}, "html": {"href": "https://bitbucket.org/gitea/test_repo"}, "avatar": {"href": "https://bytebucket.org/ravatar/%7B7b764bc5-c3f3-4910-a90b-4cdc229a66b7%7D?ts=default"}}, "name": "test_repo", "uuid": "{7b764bc5-c3f3-4910-a90b-4cdc229a66b7}"}}, "source": {"branch": {"name": "feat/test", "links": {}}, "commit": {"type": "commit", "hash": "9f733b96b98a4175276edf6a2e1231489c3bdd23", "date": "2019-11-28T15:56:02+00:00", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/gitea/test_repo/commit/9f733b96b98a4175276edf6a2e1231489c3bdd23"}, "html": {"href": "https://bitbucket.org/gitea/test_repo/commits/9f733b96b98a4175276edf6a2e1231489c3bdd23"}}}, "repository": {"type": "repository", "full_name": "gitea/test_repo", "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/gitea/test_repo"}, "html": {"href": "https://bitbucket.org/gitea/test_repo"}, "avatar": {"href": "https://bytebucket.org/ravatar/%7B7b764bc5-c3f3-4910-a90b-4cdc229a66b7%7D?ts=default"}}, "name": "test_repo", "uuid": "{7b764bc5-c3f3-4910-a90b-4cdc229a66b7}"}}, "reviewers": [], "participants": [{"type": "participant", "user": {"display_name": "Lunny Xiao", "links": {"self": {"href": "https://api.bitbucket.org/2.0/users/%7B84d46ffe-e0fa-4d3c-973f-b3ce77db43f6%7D"}, "avatar": {"href": "https://secure.gravatar.com/avatar/cfb7b37d5a38d236e451a9f8e1a29fc6?d=https%3A%2F%2Favatar-management--avatars.us-west-2.prod.public.atl-paas.net%2Finitials%2FLX-1.png"}, "html": {"href": "https://bitbucket.org/%7B84d46ffe-e0fa-4d3c-973f-b3ce77db43f6%7D/"}}, "type": "user", "uuid": "{84d46ffe-e0fa-4d3c-973f-b3ce77db43f6}", "account_id": "712020:07927e50-b64a-4fc3-a57d-dcf6945b70e6", "nickname": "Lunny Xiao"}, "role": "PARTICIPANT", "approved": true, "state": "approved", "participated_on": "2026-10-07T18:40:40.122213+00:00"}], "links": {"self": {"href": "https://api.bitbucket.org/2.0/repositories/gitea/test_repo/pullrequests/1"}, "html": {"href": "https://bitbucket.org/gitea/test_repo/pull-requests/1"}, "commits": {"href": "https://api.bitbucket.org/2.0/repositories/gitea/test_repo/pullrequests/1/commits"}, "approve": {"href": "https://api.bitbucket.org/2.0/repositories/gitea/test_repo/pullrequests/1/approve"}, "request-changes": {"href": "https://api.bitbucket.org/2.0/repositories/gitea/test_repo/pullrequests/1/request-changes"}, "diff": {"href": "https://api.bitbucket.org/2.0/repositories/gitea/test_repo/diff/gitea/test_repo:9f733b96b98a%0Dc59c9b451acc?from_pullrequest_id=1&topic=true"}, "diffstat": {"href": "https://api.bitbucket.org/2.0/repositories/gitea/test_repo/diffstat/gitea/test_repo:9f733b96b98a%0Dc59c9b451acc?from_pullrequest_id=1&topic=true"}, "comments": {"href": "https://api.bitbucket.org/2.0/repositories/gitea/test_repo/pullrequests/1/comments"}, "activity": {"href": "https://api.bitbucket.org/2.0/repositories/gitea/test_repo/pullrequests/1/activity"}, "merge": {"href": "https://api.bitbucket.org/2.0/repositories/gitea/test_repo/pullrequests/1/merge"}, "decline": {"href": "https://api.bitbucket.org/2.0/repositories/gitea/test_repo/pullrequests/1/decline"}, "statuses": {"href": "https://api.bitbucket.org/2.0/repositories/gitea/test_repo/pullrequests/1/statuses"}, "mergeability_checks": {"href": "https://api.bitbucket.org/2.0/repositories/gitea/test_repo/pullrequests/1/mergeability/checks"}}, "properties": {}, "summary": {"type": "rendered", "raw": "do not merge this PR", "markup": "markdown", "html": "do not merge this PR
"}, "merge_in_progress": null, "ai_contribution": false, "queued": false, "queue_in_progress": null}], "pagelen": 10, "size": 1, "page": 1} \ No newline at end of file diff --git a/services/migrations/bitbucket.go b/services/migrations/bitbucket.go new file mode 100644 index 00000000000..13309609d0d --- /dev/null +++ b/services/migrations/bitbucket.go @@ -0,0 +1,382 @@ +// Copyright 2026 The Gitea Authors. All rights reserved. +// SPDX-License-Identifier: MIT + +package migrations + +import ( + "cmp" + "context" + "fmt" + "hash/fnv" + "net/http" + "net/url" + "slices" + "strconv" + "strings" + "time" + + user_model "gitea.dev/models/user" + "gitea.dev/modules/json" + base "gitea.dev/modules/migration" + "gitea.dev/modules/structs" + "gitea.dev/modules/util" +) + +var ( + _ base.Downloader = &BitbucketDownloader{} + _ base.DownloaderFactory = &BitbucketDownloaderFactory{} +) + +const bitbucketWebURL = "https://bitbucket.org" + +func init() { + RegisterDownloaderFactory(&BitbucketDownloaderFactory{}) +} + +type BitbucketDownloaderFactory struct{} + +func (f *BitbucketDownloaderFactory) New(_ context.Context, opts base.MigrateOptions) (base.Downloader, error) { + cloneURL, err := url.Parse(opts.CloneAddr) + if err != nil { + return nil, err + } + fields := strings.Split(strings.Trim(cloneURL.Path, "/"), "/") + if !strings.EqualFold(cloneURL.Hostname(), "bitbucket.org") || len(fields) < 2 { // the token goes to api.bitbucket.org, so no other host's URL is accepted + return nil, fmt.Errorf("invalid Bitbucket Cloud URL %q, expected https://bitbucket.org/