"git reword" should only rewrite modified commits #1385
Labels
bug
Something isn't working
good first issue
Good for newcomers
help wanted
Extra attention is needed
Description of the bug
When I have say 9 commits in my stack, and I use "git reword" to only update the LAST commit, git-branchless still rewrites all commits.
Ideally, only the changed (and dependent) commits should get rewritten.
Expected behavior
Only the last (modified) commit should have been rewritten.
Actual behavior
All commits in the stack got rewritten.
Version of
rustc
No response
Automated bug report
Software version
git-branchless 0.9.0 (8ffbdab)
Operating system
macOS 14.6.1 (Darwin 23.6.0)
Command-line
Environment variables
Git version
Hooks
Hooks directory:
/Users/amrk/IdeaProjects/securemx/smx3/com.smxemail.remediation.manager/.git/hooks
Show 7 hooks
Hook
post-applypatch
Hook
post-checkout
Hook
post-commit
Hook
post-merge
Hook
post-rewrite
Hook
pre-auto-gc
Hook
reference-transaction
Events
Show 5 events
Event ID: 703, transaction ID: 449 (message: reword)
RefUpdateEvent { timestamp: 1723544445.026751, event_tx_id: Id(449), ref_name: ReferenceName("refs/heads/redacted-ref-0"), old_oid: fcedac8eb2362186f5c119f988afd2acbd018abd, new_oid: 15388a95b0c136430ae249f36b9e85e9b7f414f2, message: None }
RewriteEvent { timestamp: 1723544445.090125, event_tx_id: Id(449), old_commit_oid: 801d2dd151b17eb0e527f0065d2160fcc3ae018f, new_commit_oid: aefa8582e622e4061ff5fa39929e3f2879e526c7 }
RewriteEvent { timestamp: 1723544445.090125, event_tx_id: Id(449), old_commit_oid: 8bcda4c473ef01359133d18e67af2b35f76a8419, new_commit_oid: 3cedbdbe44b4386509a20156241d1530c8e640b3 }
RewriteEvent { timestamp: 1723544445.090125, event_tx_id: Id(449), old_commit_oid: 9faa2f17294fa16e652d2efe652b9e996d1f852b, new_commit_oid: 648f7025269fbd88ff5def0fe7cfaf12c2fb80fd }
RewriteEvent { timestamp: 1723544445.090125, event_tx_id: Id(449), old_commit_oid: 8980886109addde7ff767b45217e1958e5d3fb5b, new_commit_oid: 8971dbe7f027841df6b3dc6be267d8e83beafe7c }
RewriteEvent { timestamp: 1723544445.090125, event_tx_id: Id(449), old_commit_oid: fcedac8eb2362186f5c119f988afd2acbd018abd, new_commit_oid: 15388a95b0c136430ae249f36b9e85e9b7f414f2 }
RewriteEvent { timestamp: 1723544445.090125, event_tx_id: Id(449), old_commit_oid: a621b53ce7a32a19738353e5addff6eb6fd56793, new_commit_oid: c8e03f62ea09c6f9d23f248ddd572706ae6e02b2 }
RewriteEvent { timestamp: 1723544445.090125, event_tx_id: Id(449), old_commit_oid: eb7ffe8c220a6cc290755cb0ee481d02844b69a2, new_commit_oid: 90bd9cc9dbc512783e889e3f6cf5a43495dfd30d }
RewriteEvent { timestamp: 1723544445.090125, event_tx_id: Id(449), old_commit_oid: 9eb78551cb689c88016cddfacf607a8ee717347d, new_commit_oid: 49ebb160c44f6d71f6cbe03f49a3ceaa33c75eb8 }
RewriteEvent { timestamp: 1723544445.090125, event_tx_id: Id(449), old_commit_oid: 8d05f590f037992126569361bcfe406cf7abd93b, new_commit_oid: 65e1c345ef110e017b4f70e258ece548d53a3a72 }
WorkingCopySnapshot { timestamp: 1723544445.138011, event_tx_id: Id(449), head_oid: fcedac8eb2362186f5c119f988afd2acbd018abd, commit_oid: NonZeroOid(d67225d18ff2a0d8dcca3b826aa5738ea13a8381), ref_name: None }
RefUpdateEvent { timestamp: 1723544445.25557, event_tx_id: Id(449), ref_name: ReferenceName("HEAD"), old_oid: 0000000000000000000000000000000000000000, new_oid: 15388a95b0c136430ae249f36b9e85e9b7f414f2, message: None }
RefUpdateEvent { timestamp: 1723544445.534112, event_tx_id: Id(449), ref_name: ReferenceName("HEAD"), old_oid: fcedac8eb2362186f5c119f988afd2acbd018abd, new_oid: 15388a95b0c136430ae249f36b9e85e9b7f414f2, message: None }
Event ID: 697, transaction ID: 445 (message: amend)
WorkingCopySnapshot { timestamp: 1723537126.932345, event_tx_id: Id(445), head_oid: 2975945e7bbebc40831e1b6ac922fb6cf80ced53, commit_oid: NonZeroOid(44a637cea71164fba4d105bbab88ea08f688271e), ref_name: Some(ReferenceName("refs/heads/redacted-ref-0")) }
RewriteEvent { timestamp: 1723537126.932345, event_tx_id: Id(445), old_commit_oid: 2975945e7bbebc40831e1b6ac922fb6cf80ced53, new_commit_oid: fcedac8eb2362186f5c119f988afd2acbd018abd }
RefUpdateEvent { timestamp: 1723537127.07347, event_tx_id: Id(445), ref_name: ReferenceName("refs/heads/redacted-ref-0"), old_oid: 2975945e7bbebc40831e1b6ac922fb6cf80ced53, new_oid: fcedac8eb2362186f5c119f988afd2acbd018abd, message: None }
WorkingCopySnapshot { timestamp: 1723537127.101924, event_tx_id: Id(445), head_oid: fcedac8eb2362186f5c119f988afd2acbd018abd, commit_oid: NonZeroOid(b380dac42c8be3f10638a4442f35cd8bfd947fda), ref_name: Some(ReferenceName("refs/heads/redacted-ref-0")) }
RefUpdateEvent { timestamp: 1723537127.247022, event_tx_id: Id(445), ref_name: ReferenceName("HEAD"), old_oid: 0000000000000000000000000000000000000000, new_oid: fcedac8eb2362186f5c119f988afd2acbd018abd, message: None }
RefUpdateEvent { timestamp: 1723537127.247022, event_tx_id: Id(445), ref_name: ReferenceName("refs/heads/redacted-ref-0"), old_oid: fcedac8eb2362186f5c119f988afd2acbd018abd, new_oid: fcedac8eb2362186f5c119f988afd2acbd018abd, message: None }
Event ID: 694, transaction ID: 444 (message: record)
RefUpdateEvent { timestamp: 1723537104.158742, event_tx_id: Id(444), ref_name: ReferenceName("HEAD"), old_oid: 0000000000000000000000000000000000000000, new_oid: 2975945e7bbebc40831e1b6ac922fb6cf80ced53, message: None }
RefUpdateEvent { timestamp: 1723537104.158742, event_tx_id: Id(444), ref_name: ReferenceName("refs/heads/redacted-ref-0"), old_oid: 8d05f590f037992126569361bcfe406cf7abd93b, new_oid: 2975945e7bbebc40831e1b6ac922fb6cf80ced53, message: None }
CommitEvent { timestamp: 1723537072.0, event_tx_id: Id(444), commit_oid: NonZeroOid(2975945e7bbebc40831e1b6ac922fb6cf80ced53) }
Event ID: 688, transaction ID: 443 (message: amend)
WorkingCopySnapshot { timestamp: 1723523833.178152, event_tx_id: Id(443), head_oid: 8e24ce086e781ddf0b687061585b5eb037f31aa1, commit_oid: NonZeroOid(9b2716e2a9ba30c229db68cab05d84d75831e181), ref_name: Some(ReferenceName("refs/heads/redacted-ref-0")) }
RewriteEvent { timestamp: 1723523833.178152, event_tx_id: Id(443), old_commit_oid: 8e24ce086e781ddf0b687061585b5eb037f31aa1, new_commit_oid: 8d05f590f037992126569361bcfe406cf7abd93b }
RefUpdateEvent { timestamp: 1723523833.353396, event_tx_id: Id(443), ref_name: ReferenceName("refs/heads/redacted-ref-0"), old_oid: 8e24ce086e781ddf0b687061585b5eb037f31aa1, new_oid: 8d05f590f037992126569361bcfe406cf7abd93b, message: None }
WorkingCopySnapshot { timestamp: 1723523833.380721, event_tx_id: Id(443), head_oid: 8d05f590f037992126569361bcfe406cf7abd93b, commit_oid: NonZeroOid(ca51571af82fb3d3c52f4c6600a1c21cda57cea7), ref_name: Some(ReferenceName("refs/heads/redacted-ref-0")) }
RefUpdateEvent { timestamp: 1723523833.519455, event_tx_id: Id(443), ref_name: ReferenceName("HEAD"), old_oid: 0000000000000000000000000000000000000000, new_oid: 8d05f590f037992126569361bcfe406cf7abd93b, message: None }
RefUpdateEvent { timestamp: 1723523833.519455, event_tx_id: Id(443), ref_name: ReferenceName("refs/heads/redacted-ref-0"), old_oid: 8d05f590f037992126569361bcfe406cf7abd93b, new_oid: 8d05f590f037992126569361bcfe406cf7abd93b, message: None }
Event ID: 685, transaction ID: 442 (message: record)
RefUpdateEvent { timestamp: 1723522809.762482, event_tx_id: Id(442), ref_name: ReferenceName("HEAD"), old_oid: 0000000000000000000000000000000000000000, new_oid: 8e24ce086e781ddf0b687061585b5eb037f31aa1, message: None }
RefUpdateEvent { timestamp: 1723522809.762482, event_tx_id: Id(442), ref_name: ReferenceName("refs/heads/redacted-ref-0"), old_oid: a621b53ce7a32a19738353e5addff6eb6fd56793, new_oid: 8e24ce086e781ddf0b687061585b5eb037f31aa1, message: None }
CommitEvent { timestamp: 1723522662.0, event_tx_id: Id(442), commit_oid: NonZeroOid(8e24ce086e781ddf0b687061585b5eb037f31aa1) }
Version of
git-branchless
No response
Version of
git
No response
The text was updated successfully, but these errors were encountered: