Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

How do I search by commit hash

aymeric bard November 18, 2012

When using git bisect for example, we always have git hash as result. It would be nice to be able to filter or search commit by their hash instead of their commit message.

6 answers

1 accepted

20 votes
Answer accepted
stevestreeting
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
November 18, 2012

This is in the log view rather than the search view because it's about jumping to the right commit. Use the Jump to: option in the top right of the log view and select "Commit...", then type in a full or partial SHA.

aymeric bard November 24, 2012

Ok thanks. Not very discoverable though...

Like # people like this
Kris Khaira August 6, 2013

I spent 5 minutes wondering how to do this and then ended up here. It might help if that dropdown option said "Commit hash" instead of just "Commit".

Ken Taylor February 9, 2014

Is there a keyboard shortcut to bring up the jump to commit dialog?

Gili October 20, 2014

I agreed with aymeric. You should duplicate this option in the Search menu (CTRL+3).

Jeffrey Reynolds November 18, 2015

Worst location ever.

Like # people like this
Tiago June 1, 2016

this is not obvious at all. i raged for 30 minutes until i found it

 

Like Jan_Hettich likes this
Aaron Bauman June 6, 2016

Pretty dumb. The point of a hash is that it's quick and easy to find something by unique ID. Forcing user to scroll through ALL POSSIBLE HASHES EVER is a lazy UI. Furthermore, this IS now available in the search view.

Bash Xu August 14, 2016

屏幕快照 2016-08-15 下午3.55.52.png

martinwyser March 2, 2017

What is the log view? How do I get to it in the web interface`?

Like maximumpeaches likes this
robert66427 January 9, 2018

I believe the posters that are referring to "search view" and "log view" are talking about available options in the SourceTree tool provided by Atlassian; not the Bitbucket Web UI.  As best as I can tell, at least in Bitbucket Server Web UI... there doesn't appear to be any way to search by commit hash, other than to scroll to it... which isn't very helpful.

Like # people like this
Alejandro Lepervanche September 9, 2019

If you're using the Bitbucket Web UI, you can navigate to any commit nearby and edit the url with your hash like so:

http://stash/projects/yourProject/repos/yourBranch/commits/placeYourHashHere

That will take you directly to your commit.

Like # people like this
navgupt July 16, 2020

Thanks for the tip. i am able to find my commit on BitBucket UI, but furthermore,  Is there any way i could see which particular JIRA# this commit was made?

wallace_turner August 4, 2020

A picture is a thousand words

 

sourcetree.gif

Like # people like this
9 votes
Thorsten Hecht August 22, 2018

For people who are stuck in a version before 5.8 which fixed that issue there is a workaround for the commit hash

Just go inside Bitbucket Web UI to the commits on the left menu then type a slash inside the adress field of your browser and enter the hash.

it will immediately display the commit 

Sander Theetaert March 12, 2019

BEST RESPONSE EVER!!!

Urbietus October 16, 2019

CLAP! CLAP! CLAP!

Thank you!!

Like 8ivek likes this
8ivek May 20, 2020

Thank you!!!

Ky Kartchner November 10, 2020

Yes, thank you!! Works great!

2 votes
Aaron Bauman June 6, 2016
  1. Go to "Search view" (cmd-3)
  2. change "Search" select menu to "Commit SHA"
  3. type the commit hash into the search bar

 

martinwyser March 2, 2017

what is cmd-3?

Like ramsay Jattan likes this
2 votes
Mark Florian May 19, 2014

We have a lot of tags, which means that the "Jump to:" dropdown can take a few seconds to appear, when all I ever want is to search by hash/tag/branch/bookmark. These things are listed in the left hand pane of the log view, so listing them here in the dropdown is redundant. It'd be great if this could be improved. Adding a keyboard shortcut for searching by commit identifier seems to be the easiest quick fix.

0 votes
Raistlin Majere March 5, 2015

Well, currently in the latest version this option does nothing... cool.

Anton Zimin January 5, 2016

You have to wait. It's slow and does not show loading indicator.

0 votes
Kris Khaira August 6, 2013

It might help if that dropdown option said "Commit hash" instead of just "Commit".

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events