fix(dev): rebuild dist after HEAD changes (#56510)

This commit is contained in:
Tak Hoffman 2026-03-28 11:49:09 -05:00 committed by GitHub
parent 840b806c2f
commit 54313a8730
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 23 additions and 2 deletions

View file

@ -211,10 +211,10 @@ const shouldBuild = (deps) => {
const currentHead = resolveGitHead(deps);
if (currentHead && !stamp.head) {
return hasSourceMtimeChanged(stamp.mtime, deps);
return true;
}
if (currentHead && stamp.head && currentHead !== stamp.head) {
return hasSourceMtimeChanged(stamp.mtime, deps);
return true;
}
if (currentHead) {
const dirty = hasDirtySourceTree(deps);