tummychow / git-absorb

git commit --fixup, but automatic
https://crates.io/crates/git-absorb
BSD 3-Clause "New" or "Revised" License
3.35k stars 59 forks source link

Only update head_tree when we commit. #92

Closed rbartlensky closed 1 year ago

rbartlensky commented 1 year ago

Fixes the case where if we pass --dry-run the additions/deletions keep growing in number since we never "reset" the tree back.

I realized after merging #91 that I forgot to handle the --dry-run case.

tummychow commented 1 year ago

ah good catch, so if it's in dry run then it applies the patches to the head tree every time and discards them afterward

rbartlensky commented 1 year ago

ah good catch, so if it's in dry run then it applies the patches to the head tree every time and discards them afterward

yep!