summaryrefslogtreecommitdiff
path: root/t/t3602-rm-sparse-checkout.sh
AgeCommit message (Collapse)AuthorFilesLines
2021-04-08rm: honor sparse checkout patternsLibravatar Matheus Tavares1-0/+78
`git add` refrains from adding or updating index entries that are outside the current sparse checkout, but `git rm` doesn't follow the same restriction. This is somewhat counter-intuitive and inconsistent. So make `rm` honor the sparsity rules and advise on how to remove SKIP_WORKTREE entries just like `add` does. Also add some tests for the new behavior. Suggested-by: Elijah Newren <newren@gmail.com> Signed-off-by: Matheus Tavares <matheus.bernardino@usp.br> Signed-off-by: Junio C Hamano <gitster@pobox.com>