'Is it possible to search for commit by Change-Id in Gerrit?

Gerrit generated a Change-Id in commit message. Is it possible to search for a commit by this Change-Id?



Solution 1:[1]

You can also do this search using the Gerrit query command line.

All forms below are equivalent:

  • ssh -p 29418 your.gerrit.com gerrit query --format=JSON 8958202
  • ssh -p 29418 your.gerrit.com gerrit query --format=JSON change:'8958202'
  • ssh -p 29418 your.gerrit.com gerrit query --format=JSON change:'I3054034b91597e54f84f3fa2c4afbcc9f8b60e63'

Tested with gerrit v2.14

Solution 2:[2]

I found this easy way :

https://<your.gerrit.com>/plugins/gitiles/<BranchName>/+/<CommitID>

Hope this will be useful.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Enrique S. Filiage
Solution 2 Darshan Bhat