Re: [PATCH] t3706: Add test for wildcard vs literal pathspec

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

 



On Wed, Apr 16, 2025 at 6:42 PM Junio C Hamano <gitster@xxxxxxxxx> wrote:
>
> JAYATHEERTH K <jayatheerthkulkarni2005@xxxxxxxxx> writes:
>
> > I think something like git commit "*" -m "Test" also would be a great test
> > or even git rm command.
>
> Yes, there are things other than "git add" that  take pathspec (even
> "git ls-files" does so), and demonstrating the blast radious of the
> existing "bug" you fixed, with how they behave differently and
> better with your fix, would be a good thing to do.
>

Yes ls-files is also a great example, I will add them in the test.
I think for the pathspec and glob specific commands almost all the commands
share the same code, so it should work the same for all.

> But make sure you follow "dashed options first, then other args"
> convention.  I do not offhand know (and *MORE* *IMPORTANTLY*, I do
> not want anybody to depend on) what the current command line parser
> happens to do to
>
>         git commit "*" -m "Test"
>
> If you meant to say that a pathspec with glob, always write it the
> right way:
>
>         git commit -m "Test" -- "*"
>

Ok, it makes sense, I will follow this format.

> > About the windows question, I think I will see if there is any common
> > ground I could find
> > But until then I think prereq is a great option.
>
> The FUNNYNAMES prereq was invented to mark tests that rely on
> filesystem being able to handle certain letters, so that may be a
> good thing to use.

Noted will add this too, I'm still finding all the possible files and
how they could matter in this test.
Once I do that and check if the CI works or not and if I cannot make
it work with both platforms
(Which I think most probably will happen) I will add the prereq
FUNNYNAMES as intended.

-Jayatheerth





[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