Syncing and merging come to Bitbucket

When developing on a feature branch or a fork, your code can often get out of date. There are a number of reasons this might happen:

  • You’re concentrating on a feature rather than syncing.
  • You’re not yet ready to worry about integrating just yet.
  • You’re returning to a stale branch or fork to pick up where you left off.

Have you ever wished there was a simple way to update your feature branches and forks with the most recent commits from mainline? Bitbucket now automates syncing your projects without ever needing to go to the command line.

Managing feature branches

We recently added the feature branches tab to the commits page, allowing you to see what branches are ahead of your main branch. From the feature branches tab, you can now keep these feature branches in sync with your main branch with one click.

Sync branch screenshot

Merging regularly helps avoid nasty merge conflicts and lets you focus on developing new features. If you decide you’re done with a feature branch (or just forgot to close a branch after merging in a pull request), you can also delete it directly from the feature branches page.

No fork left behind

Sync fork dialog screenshot

When you’ve forked project, it can be tedious to keep up to date with the upstream repository. Bitbucket now informs you when your fork is behind, and you get the option to instantly merge in those upstream changes with a single click.

Merging in the compare view

For cases where you need to quickly merge in a branch without making a pull request, you can now do the merge directly from the compare view.

Merge button screenshot

On the Bitbucket team, when we make a pull request with hot fixes, it goes on our production branch. When we accept the pull request, we go to the compare view and merge production into our staging branch, making sure the fix makes it out both externally and internally.

Being able to sync your branches and merge through the compare view lets you manage your branches in Bitbucket from start to finish.

Sync and merge with Bitbucket

Sign up free for 5 users today using your Google, Facebook or GitHub account.