Re: [PATCH v2] sparse-checkout: create leading directory

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Elijah Newren <newren@xxxxxxxxx> writes:
> On Fri, Jan 21, 2022 at 6:05 PM Jonathan Tan <jonathantanmy@xxxxxxxxxx> wro=
> te:
> >
> > When creating the sparse-checkout file, Git does not create the leading
> > directory, "$GIT_DIR/info", if it does not exist. This causes problems
> > if the repository does not have that directory. Therefore, ensure that
> > the leading directory is created.
> >
> > This is the only "open" in builtin/sparse-checkout.c that does not have
> > a leading directory check. (The other one in write_patterns_and_update()
> > does.)
> >
> > Note that the test needs to explicitly specify a template when running
> > "git init" because the default template used in the tests has the
> > "info/" directory included.
> 
> If wanted, you could avoid that by using `git worktree add ...`;
> git-worktree will create a $GIT_DIR that does not contain an info
> subdirectory.
> 
> (No need to resubmit or anything, mostly I'm just mentioning another
> way folks might have triggered this issue.)

Ah, thanks for the information.

> Patch looks good to me:
> 
> Reviewed-by: Elijah Newren <newren@xxxxxxxxx>

Thanks for taking a look!



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux