How to change MAIN branch in BitBucket?

Have a main branch in BitBucket named "trunk" (after import from SVN).

Also have branch named "master" - branched from "trunk".

How to set "master" the main branch in BitBucket and then delete "trunk" branch?

3 answers

1 accepted

This widget could not be displayed.
git symbolic-ref HEAD refs/head/master
git branch -d trunk

refs/heads/master

NOT

refs/head/master

??

This widget could not be displayed.

In Bitbucket UI:

  1. Select the repository
  2. Select Administration
  3. In Repository Details, set Main branch

Now delete unnecessary branches with git branch -d.

In the updated Bitbucket UI, select *Settings* instead of *Administration* in Step 2.

Check permissions if you don't see the "Settings" link.

Thanks, worked

This widget could not be displayed.

After changing the main branch - when cicking on "save reporistory details" i get a wired error:

"You can't create repositories under this account."

 

Seems like you need admin access.

Suggest an answer

Log in or Sign up to answer
Atlassian Summit 2018

Meet the community IRL

Atlassian Summit is an excellent opportunity for in-person support, training, and networking.

Learn more
Community showcase
Posted Aug 10, 2018 in Bitbucket

What is your #1 piece of advice to new users getting started using Bitbucket?

Hello Community! My name is Claire Maynard, and I’m a Product Marketing Manager on the Bitbucket team. I’m interested in hearing what advice or tips you have for new users getting started on ...

246 views 14 2
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you