Beginner Bitbucket: pull request after merge without a Fork

I started using Bitbucket (with mercurial) by pulling a repository directly from a collaborator's Bitbucket account. That is, I never used Bitbucket to create a Fork to my own Bitbucket account. [I now realize I should have created a Fork on Bitbucket then pulled that fork to my local machine]. Anyway, I just completed a significant merge of the code on my local machine, and I want my collaborator to pull the merged code back to the main trunk. But he can't pull it directly from my local machine. I'm not authorized to push it up to his Bitbucket account. Any idea what's the best way out of this predicament?

Thanks, Jared

1 answer

1 accepted

You can still fix this yourself, as long as you have read access to the original repository. Go to that repo, and create a new fork. Then, on your local machine, update the remote URL of the repository to point to the fork you created in your account (see the Mercurial section of this guide). Then, push your code into your fork. A simple push, perhaps with --new-branch should do it. Then, create a Pull Request from your fork to your collaborator.

Thanks a lot, worked like a charm!

P.S.: I had not thought of this partly because I have another fork from the same repository, and I didn't realize you could have 2 different forks from the same repo (as long as you give the forks different names).

Suggest an answer

Log in or Sign up to answer
How to earn badges on the Atlassian Community

How to earn badges on the Atlassian Community

Badges are a great way to show off community activity, whether you’re a newbie or a Champion.

Learn more
Community showcase
Posted Jun 12, 2018 in Bitbucket

Do you use any Atlassian products for your personal projects?

After spinning my wheels trying to get organized enough to write a book for National Novel Writing Month (NaNoWriMo) I took my affinity for Atlassian products from my work life and decided to tr...

22,993 views 26 12
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