Thread (20 messages) flat view 20 messages, 4 authors, 2016-06-15

Re: [PATCH 3/3] git-read-tree.txt: correct sparse-checkout and skip-worktree description

From: Michael J Gruber <hidden>
Date: 2016-06-15 22:52:05

Nguyen Thai Ngoc Duy venit, vidit, dixit 21.09.2011 11:26:
On Wed, Sep 21, 2011 at 5:48 PM, Michael J Gruber
[off-list ref] wrote:
quoted
The description of .git/info/sparse-checkout and
skip-worktree is exactly the opposite of what is true, which is:

If a file matches a pattern in sparse-checkout, then (it is to be
checked out and therefore) skip-worktree is unset for that file;
otherwise, it is set (so that it is not checked out).

Currently, the opposite is documented, and (consistently) read-tree's
behavior with respect to bit flips is descibed incorrectly.

Fix it.
Ack.
quoted
In hindsight, it would have been much better to have a "sparse-ignore"
or "sparse-skip" file so that an empty file would mean a full checkout,
and the file logic would be analogous to that of .gitignore, excludes
and skip-worktree.
.gitignore works towards excluding files. No rule means no excluding.
sparse-checkout file works towards including files, no rule means no
inclusion.
Sure, but with a "sparse-skip" rather than "sparse-checkout", we would
not even need an additional config variable, and the skip-worktree
centered explanations would follow the same logic (no need for the
additional negation) as the ignore files and the new sparse-skip file.
Also, I'm not sure whether more sparse users say "I want only that
subdir." than "I don't want that subdir."

But it's there to stay, of course.

Cheers,
Michael
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help