From: "Nguyen Thai Ngoc Duy" <pclouds@gmail.com>
To: "Junio C Hamano" <gitster@pobox.com>
Cc: git@vger.kernel.org
Subject: Re: [RFC PATCH 0/9] Narrow/Sparse checkout round 3: "easy mode"
Date: Sun, 17 Aug 2008 12:12:50 +0700 [thread overview]
Message-ID: <fcaeb9bf0808162212y756465a5ib7ce3a8849765033@mail.gmail.com> (raw)
In-Reply-To: <7v1w0pdze0.fsf@gitster.siamese.dyndns.org>
On 8/16/08, Junio C Hamano <gitster@pobox.com> wrote:
> Nguyen Thai Ngoc Duy <pclouds@gmail.com> writes:
> > Another difference from the last round is "narrow rules" will not be preserved
> > when switching branches. When you switch branch with no option, you will get
> > full checkout. You may want to use --path|--add-path|--remove-path when
> > switching branches to have narrow checkout again.
>
>
> You could save the "narrow rules" in the extension section of the index.
> If the final form of this series needs to use a separate CE_NO_CHECKOUT
> bit (which would make the resulting index incompatible with the current
> git), the narrow rules section can be marked as "your git must understand
> this" class of extension to make sure that people do not mistakenly access
> an index written by this new version of git with the current or older git.
The problem is "narrow rules" may change over time in a way that git
may handle it wrong. Assume that you have a directory with two files:
a and b. You first narrow checkout a (which would save the rule
"checkout a"). Then you do "git checkout b". When you update HEAD,
what should happen?
- consider only a and b in narrow area (new files not counted)
- consider the whole directory in narrow area (new files counted)
This does not matter until we implement strict mode that only checkout
new files inside narrow area (the usage is similar to submodule).
> > Now back to technical POV. I did not reuse CE_VALID (assume unchanged) bit
> > because it has been used for core.ignorestat.
>
>
> I am not sure what's the relation between these two.
Because the usage is different? When you "git update-index foo" with
core.ignorestat=1, it will mark it CE_VALID. And if the same bit is
used for narrow checkout, the file is considered not existing in
workdir. I'd expect foo is still in my narrow area after "git
update-index foo".
--
Duy
next prev parent reply other threads:[~2008-08-17 5:13 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-08-15 14:24 [RFC PATCH 0/9] Narrow/Sparse checkout round 3: "easy mode" Nguyễn Thái Ngọc Duy
2008-08-16 10:31 ` Junio C Hamano
2008-08-17 5:12 ` Nguyen Thai Ngoc Duy [this message]
2008-08-17 5:50 ` Junio C Hamano
2008-08-17 6:10 ` Junio C Hamano
2008-08-17 9:49 ` [RFC PATCH 0/9] Narrow/Sparse checkout round 3: Eric Raible
2008-08-19 9:06 ` Junio C Hamano
2008-08-17 13:36 ` [RFC PATCH 0/9] Narrow/Sparse checkout round 3: "easy mode" Nguyen Thai Ngoc Duy
2008-08-19 21:10 ` James Pickens
2008-08-30 9:21 ` Nguyen Thai Ngoc Duy
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=fcaeb9bf0808162212y756465a5ib7ce3a8849765033@mail.gmail.com \
--to=pclouds@gmail.com \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).