diff options
| author | DanConwayDev <DanConwayDev@protonmail.com> | 2026-03-30 10:54:31 +0000 |
|---|---|---|
| committer | DanConwayDev <DanConwayDev@protonmail.com> | 2026-03-30 16:29:20 +0000 |
| commit | 33a72aa745ea6b6594bacfb71ea8ff2778f9b748 (patch) | |
| tree | 1dcc9e5a73f89a84390b20797dd4c64d5bdef280 /test_utils/src/lib.rs | |
| parent | 3a03cca6eb6597c19f5146c5f0d18f9230eb0fae (diff) | |
fix(patch): don't error on commit id mismatch for pgp-signed commits
When applying a patch with a pgp signature, commit_create_buffer +
commit_signed reconstructs the signed commit object. The resulting OID
matches the original only if commit_create_buffer produces the exact
same bytes that git originally signed — which isn't guaranteed across
different git implementations or versions.
The existing amend workaround (which re-applies author/committer to
recover the correct OID) is preserved for unsigned commits. For
pgp-signed commits the amend still runs but the mismatch bail is
skipped, since the tree, author, committer, message and signature are
all correct regardless of the OID difference.
Diffstat (limited to 'test_utils/src/lib.rs')
0 files changed, 0 insertions, 0 deletions