git filter-branch not removing commits when it should in 2.7.0
- From
- John Fultz <jfultz@wolfram.com>
- Date
- Jan 19, 2016, 20:48 UTC
- Message-ID
- <AF975DD2-988F-47A8-BFC3-3BBC27419305@wolfram.com>
This seems to be a 2.7.0 regression in filter-branch. The bug is reproducible on Mac/Windows (haven't tried Linux) in the 2.7.0 production releases.
Make an empty repo and put an empty commit in the history. E.g.,
echo > foo && git add . && git commit -m "commit 1" && git commit --allow-empty -m "commit 2"
Now try to use filter-branch to remove the empty commit. Both of the following methods leave master unchanged, but both worked in 2.6.4:
git filter-branch --prune-empty git filter-branch --commit-filter 'git_commit_non_empty_tree "$@"'
Let me know if you need any more information. Thanks.
Sincerely,
John Fultz jfultz@wolfram.com User Interface Group Wolfram Research, Inc.