SIGN IN SIGN UP

[DevTools] Use deterministic extension commit hashes (#37305)

## Summary

`git show --format=%h` is not stable: abbreviation length depends on
`core.abbrev` and how unique the prefix is in that clone. Two rebuilds
of the same commit can therefore embed different strings in
`DEVTOOLS_VERSION` and the extension manifest.

Always take the full hash (`%H`) and slice it to 10 characters so the
value is the same everywhere.

This also removes the `build/COMMIT_SHA` fallback used when Mozilla
rebuilds from a git archive (no `.git`). That path used a different
length (7) and a different source, so it could not match a git checkout
of the same commit. Firefox source review should rebuild from a checkout
of the commit in #37307, not from the tarball alone.

Stack: this PR → #37306 → #37307.

## How did you test this change?

Build-script only. `getGitCommit()` now returns `HEAD` sliced to 10
chars, independent of `core.abbrev`.

Co-authored-by: Ruslan Lesiutin <hoxy@meta.com>
R
Ruslan Lesiutin committed
a7ef01ae4ad19971a0b83ef3dd377afeaef26816
Parent: 084f5f2
Committed by GitHub <noreply@github.com> on 9/2/2026, 12:28:31 PM