How to compare two commits in BitBucket?
I came across this question while looking for a way to compare a single file across two different commits. The instructions for doing so are slightly different than those above, so I wanted to share:
- Browse to the file in question in the "Source" view
- Drop down the file's view option and select "Diff":
- Once the file's diff has loaded, drop down the history options and select the commits that you want to compare between:
BitBucket Cloud (bitbucket.org) supports commit comparison on the branch compare page:
- Navigate to a repo
- Click the '+' menu in the left-nav
- Click 'Compare branches and tags'
- Paste your commit hashes into the search fields in the branch/tag dropdowns
- Click 'Compare'
This URL worked for me: https://bitbucket.org/<OWNER>/<PROJECT>/branches/compare/<commit1>..<commit2>#diff
, short hashes can also be used.
Screenshot: