Make cvsexportcommit remove files too.
PATCH 1/1 Make cvsexportcommit remove files too.
From: Robin Rosenberg <[email protected]>
---
git-cvsexportcommit.perl | 2 +- t/t9200-git-cvsexportcommit.sh | 12 ++++++++++++ 2 files changed, 13 insertions(+), 1 deletions(-)
git-cvsexportcommit.perl +1 -1
@@ -142,7 +142,7 @@ foreach my $f (@files) { if ($fields[4] eq 'M') { push @mfiles, $fields[5]; } - if ($fields[4] eq 'R') { + if ($fields[4] eq 'D') { push @dfiles, $fields[5]; } }
t/t9200-git-cvsexportcommit.sh +12 -0
@@ -52,4 +52,16 @@ test_expect_success \ test $(cat CVS/Entries|wc -l) = 3 )' +test_expect_success \ + 'Remove file with spaces in file name' \ + 'echo Ok then >"with spaces.txt" && + rm -v "with spaces.txt" && \ + git rm "with spaces.txt" && \ + git commit -a -m "Remove file" && + id=$(git rev-list --max-count=1 HEAD) && + (cd $CVSWORK && + git-cvsexportcommit.perl -v -c $id && + test $(cat CVS/Entries|wc -l) = 2 + )' + test_done