youngmon/atlassian-qna huggingface dataset:
Is there a plugin or tools to monitor the overall changes were happening in bitbucket?
Asked by ramesh prasath:

Hi all,  

I would like to get insights on how many lines of codes were added/deleted, how many new files were added/deleted in a particular repo/branch.

Overall am looking for a tool or plugin to integrate with the bitbucket datacenter, which will give monthly or yearly insights about the changes that were happened in my repo/branch under a project.  

Please let me know if there is any free/paid tool available to help with this need or any other ideas to achieve this goal are also appreciated.

Thanks in advance.


Answers:
author: seanaty
body: I don't have first hand knowledge of this app, I only know if it's existence, but I would checkout this Atlassian marketplace application. It's called "Awesome Graphs"

<https://marketplace.atlassian.com/apps/1210934/awesome-graphs-for-bitbucket>


Tags: bitbucket-server

server
Branch model - Extend the existing Branch prefixes in order to use them as branch Type
Asked by Panagiotis Parthenis:

Hello Community,

I am a newbie at bitbucket. ? would like to define new custom Branch prefixes in order to use them for JIRA as branch Type.

In more detail, I would like to have extended the default branch prefixes in order to use them as a brach type.

![xxx.png](https://community.atlassian.com/t5/image/serverpage/image-id/190809i0C609541AA1100F3/image-size/large?v=v2&px=999 "xxx.png")

I would like to add the following branch prefixes and types mapping.

* feature/xxxx ---\> Feature (existing)
* legacy-fix/xxxx ---\> Legacy
* performance-fix/xxxx ---\> Performance
* technical-depth-fix/xxxx ---\> Technical Depth

As we use the same issues types.

I really appreciate your time and collaboration.

Best regards,

Panagiotis Parthenis


Answers:
author: Theodora Boudale
body: Hi Panagiotis,

I'm afraid that it is not possible to add new prefixes on the Branching model page at the moment.

We have a feature request about this in our issue tracker:

* <https://jira.atlassian.com/browse/BCLOUD-10744>

Since you're interested in that feature, I would suggest adding your vote to the feature request (by selecting the **Vote for this issue** link) as the number of votes helps the development team and product managers better understand the demand for new features.

You are more than welcome to leave any feedback, and you can also add yourself as a watcher (by selecting the **Start watching this issue** link) if you'd like to get notified via email on updates.

Implementation of new features is done as per our policy [here](https://confluence.atlassian.com/support/implementation-of-new-features-policy-201294576.html) and any updates will be posted in the feature request.

Kind regards,  
Theodora


Tags: bitbucket-cloud

cloud
Git Pull failed: Authentication failed for 'https:
Asked by Akshay:

Git Pull failed: Authentication failed for 'https:...................git'


Answers:
author: Karthick S
body: Hello [@Akshay](/t5/user/viewprofilepage/user-id/4849706)  

Welcome to the community!  

As per the Bitbucket [communication](https://bitbucket.org/blog/deprecating-atlassian-account-password-for-bitbucket-api-and-git-activity#:~:text=Deprecating%20Atlassian%20account%20password%20for%20Bitbucket%20API%20and%20Git%20activity,-September%2003%2C%202021&text=Starting%20Sep%2013%2C%202021%2C%20new,to%20use%20Bitbucket%20app%20passwords.), Atlassian account passwords are deprecated for Bitbucket API calls and HTTPS git activity (clone, push, pull and fetch), and are being replaced by App Passwords.

App passwords are meant to substitute your real account password and are designed to be used for a specific purpose and limited permissions. They can be easily created and revoked when needed.

If you want to check more information about the App Password, you can reference this [documentation](https://bitbucket.org/account/settings/app-passwords/).

Please note, that the command expects the username, not the email ID. You can get the username from your [personal settings](https://bitbucket.org/account/settings/).   

I hope this helps.  

Regards,  
Karthick S


Tags: bitbucket-cloud

cloud
Reporting Malware Abuse
Asked by Hugo Davidson:

*I honest to god thought this was going to be a lot easier. Turns out you're not allowed to contact the support team directly if you're not a paid member.*

But anyways, onto the point.

I'm a malware researcher and found that there is malware being hosted on your platform at <https://bitbucket.org/vac44401/zxczxczc/downloads/> - used in a Vidar (ArkeiStealer) loader campaign.

VT Report: <https://www.virustotal.com/gui/file/c1e4377a3cf1c7afe32204d7d9e0244d7c04ab1f6435920cd5155ab92deea552/detection>

Intezer Analysis: <https://analyze.intezer.com/analyses/c7441775-29a0-4df1-8d0b-3080562408e0>

Original Malware Analysis: <https://app.any.run/tasks/568ad57d-d080-4099-b2f2-5d9dabcb9405> (note the HTTP requests section pointing to a bitbucket URL).

Any assistance with taking this down would be much appreciated.


Answers:
author: Caroline R
body: Hi, [@Hugo Davidson](/t5/user/viewprofilepage/user-id/4849846), welcome to the community!

Thank you for reporting this case to us, we really appreciated it. We have confirmed that the repository contained malicious content, so we have taken down the account as malware.

Please feel free to share any additional questions regarding this case.

Kind regards,  
Caroline


Tags: bitbucket-cloud

cloud
Not able to login into bitbucket account
Asked by Vinay:

Hello,

I had hosted C++ code on a bitbucket repository during my study at university. Now it's been more than 4 years since I have graduated from the university and my professor wants access to this bitbucket repository. I would like to grant him an access. For that I need to login, but I can't.

Why can't I login?  
I used to login into the bitbucket account using username during my time at the university. Bitbucket moved to Atlassian sometime and now requires an email address to login instead of username. Now here is the real issue. As soon as I type the email address associated with the account (name@domain.nl), it takes (redirects) to the university page and then asks me to login with the university login details, which **don't** exist. The email account has been scrapped by the university since I graduated. The university has also already told me that they will not be able to restart the account.

Thus my question:

How can I get access to the account ? Can I login using username somehow? Or can I skip the redirect somehow? Is it possible to resolve this via command line? I know the username and password.

PS: I have posted this question via an alternate account.

Thanks and kind regards,  
Vinay


Answers:
author: Caroline R
body: Hi, [@Vinay](/t5/user/viewprofilepage/user-id/4849269) welcome to the community!

As we will need to know your previous username to further investigate this case, I have created an internal ticket for you using the email of your community account, so you don't have to share this information here.

You should have received an email with a link to the support ticket. Just in case you haven't received it, please feel free to let me know and I can post the ticket URL here. The ticket will be visible only to you and Atlassian staff, no one else can view its contents even if they have the URL.

Please feel free to share any questions if needed.

Kind regards,  
Caroline


Tags: cloud
How to enforce branch naming policy ?
Asked by Panagiotis Parthenis:

Hello Community,

I am a Panagiotis, and software engineer who likes to improve his skill and try new things.

I am a newbie at bitbucket and I would like some guides and support from the community.

My case is simple I would like to enforce a branch naming policy for my Repository. In more detail, my goal is to have only the branch following names and avoid (reject) all other branches which not follow my convention. The branches should follow the convention:

* feature-xxxx
* bug-xxxx-xxxx
* legacy-fix-xxxx
* performance-fix-xxxx
* technical-depth-fix-xxx

So If an unexpired use tries to push the branch without the previous pattern matching the push branch should be rejected

For simplicity let's assume we should follow only the convention \`feature-xxxx\`. My first thought was to set a pattern for the branch permission session, so I try to set the following patter

\* \| !(feature-\*)

With Write access NONE and Merge via pull request NONE too. But it didn't work. :\|

Then I try to have separate the rules

**Rule1**

pattern \*

Write access none

Merge via pull request none

**Rule2**

pattern \^feature-\*

Write access anybody

Merge via pull request anybody

But it didn't work that too :(

I really appreciate some advice. Thank you all for your time and Collaboration !!

Best Regards,

Panagiotis Parthenis


Answers:
author: Ben
body: Hey Panagiotis,

Welcome to the Bitbucket Cloud community!

I am reaching out as I have noticed that you have not yet received a reply from our community. The branch permissions feature is only used to determine READ/WRITE privileges for certain branches and does not restrict users from being able to push new branches that do not match naming conventions.

I have reached out to our development team to create a feature request on your behalf however to potentially include this functionality in Bitbucket Cloud:  
<https://jira.atlassian.com/browse/BCLOUD-21943>

Feel free to "Watch" this feature request for further updates.

Cheers!

- Ben (Bitbucket Cloud Support)


Tags: atl-gruland

bitbucket-cloud

branch
When i try to access to configure bitbucket-pipelines.yml button only appears a message
Asked by Alejandro Alvarado:

I trying to configure the **bitbucket-pipelines.yml**but, when i try to do this, the screen what i want to see is this

![Wordpress Bitbucket screenshot 6](https://bs-uploads.toptal.io/blackfish-uploads/uploaded_file/file/53870/image-1569389506075-e11fa17515d6f7526a906624983c8f88.png)

But i see this,

![Captura.PNG](/t5/image/serverpage/image-id/190734i4953FFA00D8FCE76/image-size/large?v=v2&px=999 "Captura.PNG")

What i need to do?


Answers:
author: Theodora Boudale
body: Hi [@Alejandro Alvarado](/t5/user/viewprofilepage/user-id/4849039),

The onboarding wizard no longer shows for a repo if you first enable Pipelines from **Repository settings** .  
We have a bug report for this in our issue tracker:

* <https://jira.atlassian.com/browse/BCLOUD-20669>

If you want to access these templates, you can:

1. Create a new repository for test purposes
2. Do NOT enable Pipelines for this new repo from Repository settings. Instead, select Pipelines from the sidebar at the left while viewing the repo: ![Screenshot 2022-04-05 at 13.07.39.png](https://community.atlassian.com/t5/image/serverpage/image-id/191583iCDEB1905B3CD9F8B/image-size/large?v=v2&px=999 "Screenshot 2022-04-05 at 13.07.39.png")
3. You will then be able to view the templates and select the template you want.
4. Afterwards, open the repository where you actually want to set up Pipelines. Create a new file in this repo with the name bitbucket-pipelines.yml, and you can copy-paste the template from step 3 and adjust it as needed.

Kind regards,  
Theodora


author: Robert Wen_ReleaseTEAM_
body: Hello [@Alejandro Alvarado](/t5/user/viewprofilepage/user-id/4849039) ! Welcome to the Atlassian Community!

If you don't have a bitbucket-pipelines.yml file in your Bitbucket repo, The Pipelines page will open up to the first image you're showing. If you have that file, the guidance won't show any more (which I think is kinda wrong).


Tags: bitbucket-cloud

cloud
Bitbucket on Windows
Asked by Kevin Votenz:

We are purchasing a 2000 user license for Bitbucket data center and we have a question on a note in the documentation. The documentation says that Bitbucket is not supported for 500+ users. Is this just because of performance or will we not be able to apply the license?


Answers:
author: Christian Glockner
body: Hi Kevin,

You will be able to apply the license, but you will not be able to receive any support from Atlassian. Also, Bitbucket Server 8.0 will not support Windows anymore, full stop, so you won't be able to upgrade.

Cheers,

Christian

Premier Support Engineer

Atlassian


Tags: bitbucket-server

server
Using build files from docker container in other pipeline steps
Asked by James Wolensky:

In the first step in my pipeline, I am building my application with docker and deploying it to AWS ECR. However, in a follow up step, I would like to use those same build files I uploaded to AWS for a shell script. They need to be the same files I uploaded because each \`npm run build\` creates different hashed file names. How can I export the build folder from step 1 to use in future pipeline steps?

```
- step: &build-staging
    name: Build and publish docker image
    services:
      - docker
    caches:
      - docker
    script:
      - docker build -t web . #/dist folder gets created and uploaded to AWS
      - pipe: atlassian/aws-ecr-push-image:1.4.2

```

```
- step: &upload-source-maps-staging
    name: Upload source maps
    script:
      - npm ci
      - /bin/bash upload-source-maps.sh #I want to use the /dist folder created in the build-staging step above
```


Answers:
author: Theodora Boudale
body: Hi James and welcome to the community!

If the dist folder is created in the clone directory, then you can define it as an artifact so that its contents become available for the next step. You can do this the following way:

```
- step: &build-staging
    name: Build and publish docker image
    services:
      - docker
    caches:
      - docker
    script:
      - docker build -t web . #/dist folder gets created and uploaded to AWS
      - pipe: atlassian/aws-ecr-push-image:1.4.2
    artifacts:
      - dist/**
```

You can check the following documentation page for more info:

* <https://support.atlassian.com/bitbucket-cloud/docs/use-artifacts-in-steps/>

Keep in mind that the step that generates the artifact and the steps that use it cannot be parallel steps.

Please feel free to let me know how it goes and if you have any questions.

Kind regards,  
Theodora


Tags: bitbucket-cloud

cloud
What's the difference between a private workspace and a public one?
Asked by Ahmad Atiyah:

When creating a private workspace in BB Cloud, does that mean only I can access that workspace? And if it was public, do users from outside the organization have access to that workspace?


Answers:
author: seanaty
body: From what I gather the difference is a private workspace won't show any public directory of public repositories.

I think this is a very oft-forgotten feature of Bitbucket but if you go to bitbucket.org/\<workspace\> in an incognito window (e.g. you're an unauthenticated member of the general public) then Bitbucket will display a list of the company's **public** repositories. It's a way for companies to showcase their open source projects similar to Github.

If you opt to have your workspace private you'll see a snarky message instead of a list of public repositories. Keep in mind this doesn't actually control any access to repositories whatsoever. It merely controls the absence/presence of your workspaces public repositories. Setting a workspace to private will not make any repositories private.


Tags: bitbucket-cloud

cloud
Not receiving bitbucket's invitation
Asked by Mariana Silva:

I'm not receiving bitbucket's invitation emails.


Answers:
author: Caroline R
body: Hi, Mariana, welcome to the community!

I reviewed your email and confirmed that it had a block on the server that prevented emails from being sent to you. This can occur when the system tries to send an email to the user and the account does not exist, is not activated yet, or rejects the email for some internal reason.

In this case, I have removed the block from your email. Could you please ask your team to **remove** the invitation and send you a new one? They can do this by following the next steps:

In case they have invited you to a **specific repository**:

* Access the workspace \> Go to the repo they have invited you to;

* Access the **Repository Settings** \> **User and group access;**

* Click on the "invitation pending";

* Select the "**Cancel invitation**" option to remove the invitation;

* Add your email again to send a new invitation.

In case they have invited you to a **group on this workspace**:

* Access the workspace \> **Settings**;

* Access **User groups** \> Open the group they have invited you to**;**

* Click on the "invitation pending";

* Select the "Cancel invitation" option to remove the invitation;

* Add your email again to send a new invitation.

Please let me know how it goes and feel free to share any additional questions or concerns regarding this case.

Kind regards,  
Caroline

comments: author: Mariana Silva
body: Thanks, worked for me.


author: Caroline R
body: Thanks for your confirmation, Mariana! I'm glad to know it worked.

Have a great weekend!


author: Mariana Silva
body: Thank you! For you too!


Tags: cloud
Fork the repo using rest api 2.0
Asked by Sangameshwar Sangaeshwar:

Hi Team,

I am planning to Fork a repo from existing repo in same workspace, and as I see this can be achieved with rest api 2.0. While doing as described in the documentation facing  
{  
"type": "error",  
"error": {  
"message": "Something went wrong",  
"id": "71d7d97157e045ce8dd74348e52384f8"  
}  
}  
below is my request  
**URL** : <https://api.bitbucket.org/2.0/repositories/sangameshwar550/helloworld>  
****Body :****  
{  
"name": "helloworld",  
"workspace": {  
"slug": "sangameshwar550"  
}  
}  
my workspace id is **sangameshwar550** \& my existing repo is **helloworld**and I want to name the new repo as hellow_react  
Am I missing anything here.  
Best Regards,  
Sanga


Answers:
author: Mark C
body: Hi [@Sangameshwar Sangaeshwar](/t5/user/viewprofilepage/user-id/4848058)

Welcome to the community.

Based on the error message ID, it seems you can't rename the public repository because the project it's on is set as "private".

For this, you'll need to make sure your project setting is set to public.  
You can check this by going to your project setting:

1. Go to your workspace - <https://bitbucket.org/workspace_id/>
2. Click **Projects**
3. Click the project name
4. Click **Project settings**
5. Under **Privacy**, make sure "Private project" is unchecked

Also, to rename a repository, the below CURL command works for me.

```
curl -X PUT -u bb_username:app_password -H 'Content-Type: application/json' "https://api.bitbucket.org/2.0/repositories/workspace_id/repo_name" -d '{"name": "new_repo_name"}'
```

![](https://getsupport.atlassian.com/images/icons/emoticons/information.png) Here, you'll need to use your Bitbucket Cloud username and an [App password](https://support.atlassian.com/bitbucket-cloud/docs/app-passwords/)

You can also check [this](https://developer.atlassian.com/cloud/bitbucket/rest/api-group-repositories/#api-repositories-workspace-repo-slug-put) documentation about it.

Hope it helps and let me know how it goes.

Regards,  
Mark C


Tags: bitbucket-cloud

cloud

fork

rest-api
New UI - Branch View - How to see approved commits at a glance?
Asked by NickS:

When looking at a branch with a list of commits, I can no longer see if a commit has been approved. Why is this? is there anyway to restore this functionality?


Answers:
author: Mark C
body: Hi [@NickS](/t5/user/viewprofilepage/user-id/2156164)

Thank you for reaching out to the community.

Unfortunately, this is currently a known issue where the new branch UI doesn't show approve commit icon and we do have the relevant request for it that can be tracked through this link. - <https://jira.atlassian.com/browse/BCLOUD-20750>  
You can add your feedback there, upvote, and watch it so that you'll be notified of any updates from our team when the feature becomes available again on Bitbucket Cloud.

Do let me know if you have further questions that I can help with.

Regards,  
Mark C


Tags: bitbucket-cloud

cloud
JIRA-BITBUCKET
Asked by Abdullah Dursun:

I have jira and bitbucket instance and I need to write a script to create bitbucket project and repository with the information from JIRA. I know python so have to do it with python:

1. Script should select issues of JIRA with project key in my case it is 'BR' and status To Do.  
2. Script should read values of Bitbucket Project Name, Bitbucket Repository Name fields  
3. Script should open a new Bitbucket project with Bitbucket Project Name if the project not exists  
4. Script should open a new Bitbucket repository with Bitbucket Repository Name under project with Bitbucket Project Name  
5. Script should update(create transition) JIRA issue. After the process JIRA issue should have status "Done"

Could someone help me about this. Thank you in advance!


Answers:
author: Aron Gombas _Midori_
body: The good news is that, I think, Python is the perfect tool to solve this.

You have to make calls to the Jira ad Bitbucket REST APIs. The REST API endpoints are very well documented and you can find Python examples, as well.

Hints:

For 1, just run a JQL query like this via the REST API: "project=BR and status=To Do".

Then iterate over the result, pick the values of the fields you mentioned, connect to Bitbucket, check the existence, create if not existing yet, and so on.

It is not very hard, good luck!


author: Diana_Architect_ZigiWave
body: [@Abdullah Dursun](/t5/user/viewprofilepage/user-id/4847925) hi there! I see two very good solutions pointed out in the comments above. I'd like to simply add an alternative way of connecting the two systems. You can use ZigiOps. It's an external no-code tool, that connects the systems instantly and allows you to transfer the information you need. You can also sync the data between them because it establishes a bi-directional connection. Feel free to look at it as a reference for future projects and even [book a demo](https://bit.ly/3pXlpg3) to see how it can help you.

Regards, Diana (ZigiWave)


author: Karthick S
body: Hello [@Abdullah Dursun](/t5/user/viewprofilepage/user-id/4847925)  

Welcome to the community!

You can check various REST APIs for Bitbucket Cloud [here](https://developer.atlassian.com/cloud/bitbucket/rest/intro/%20) which you may use for the custom scripting.

I hope this helps.

Kind regards,

Karthick S


Tags: bitbucket-cloud

cloud

jira
Repository size exceeds the limit. Would you please run `git gc` ?
Asked by androiddevimedrix:

Repository size exceeds the limit. Would you please run \`git gc\` ?


Answers:
author: Caroline R
body: Hi, [@androiddevimedrix](/t5/user/viewprofilepage/user-id/3192143), thank you for reaching out to Atlassian Community.

I found one repository under your workspace that was showing 1.5 GB, is this the one you are referring to? If that's the case, I ran a GC and managed to reduce its size to 706.4 MB.

Please let me know if this is the repo and feel free to share any additional information regarding this case.

Kind regards,   
Caroline


Tags: bitbucket-cloud

cloud