Merge branch 'dp/filter-branch-prune-empty'

"git filter-branch --prune-empty" drops a single-parent commit that
becomes a no-op, but did not drop a root commit whose tree is empty.

* dp/filter-branch-prune-empty:
  p7000: add test for filter-branch with --prune-empty
  filter-branch: fix --prune-empty on parentless commits
  t7003: ensure --prune-empty removes entire branch when applicable
  t7003: ensure --prune-empty can prune root commit
This commit is contained in:
Junio C Hamano
2017-03-14 15:23:19 -07:00
4 changed files with 50 additions and 8 deletions

View File

@ -16,4 +16,9 @@ test_perf 'noop filter' '
git filter-branch -f base..HEAD
'
test_perf 'noop prune-empty' '
git checkout --detach tip &&
git filter-branch -f --prune-empty base..HEAD
'
test_done