Message ID | cover.1613593946.git.matheus.bernardino@usp.br (mailing list archive) |
---|---|
Headers | show |
Series | add/rm: honor sparse checkout and warn on sparse paths | expand |
Hi, Sorry for the delay in getting back to you. On Wed, Feb 17, 2021 at 1:02 PM Matheus Tavares <matheus.bernardino@usp.br> wrote: > > This is based on the discussion at [1]. It makes `rm` honor sparse > checkouts and adds a warning to both `rm` and `add`, for the case where > a pathspec _only_ matches skip-worktree entries. The first two patches > are somewhat unrelated fixes, but they are used by the later patches. > > [1]: https://lore.kernel.org/git/CABPp-BHwNoVnooqDFPAsZxBT9aR5Dwk5D9sDRCvYSb8akxAJgA@mail.gmail.com/ I thought you said you wouldn't have time to look at git-add. Are there other commands you don't have time to look at? I've got a few suggestions... :-) Thanks so much for working on this; much appreciated. I've looked over the patch series, and am obviously a fan of the general thrust. I didn't spot anything additional to point out; Junio already looked over it pretty closely it appears. I did add a comment answering one of his questions, but that's it. > Matheus Tavares (7): > add --chmod: don't update index when --dry-run is used > add: include magic part of pathspec on --refresh error > t3705: add tests for `git add` in sparse checkouts > add: make --chmod and --renormalize honor sparse checkouts > pathspec: allow to ignore SKIP_WORKTREE entries on index matching > add: warn when pathspec only matches SKIP_WORKTREE entries > rm: honor sparse checkout patterns > > Documentation/config/advice.txt | 4 + > Documentation/git-rm.txt | 4 +- > advice.c | 19 +++++ > advice.h | 4 + > builtin/add.c | 72 ++++++++++++++---- > builtin/check-ignore.c | 2 +- > builtin/rm.c | 35 ++++++--- > pathspec.c | 25 ++++++- > pathspec.h | 13 +++- > read-cache.c | 3 +- > t/t3600-rm.sh | 54 ++++++++++++++ > t/t3700-add.sh | 26 +++++++ > t/t3705-add-sparse-checkout.sh | 122 +++++++++++++++++++++++++++++++ > t/t7011-skip-worktree-reading.sh | 5 -- > t/t7012-skip-worktree-writing.sh | 19 ----- > 15 files changed, 349 insertions(+), 58 deletions(-) > create mode 100755 t/t3705-add-sparse-checkout.sh > > -- > 2.29.2