Re: [BUG] ** glob pattern in git diff doesn't match root directory

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

 



=?utf-8?B?w4Z2YXIgQXJuZmrDtnLDsA==?= Bjarmason wrote:
> On Sat, Apr 24 2021, Felipe Contreras wrote:

> > I stumbled upoon a very similar issue (I wanted to find all the *.jpg in
> > the repository). I couldn't find another way to do it but:
> >
> >   git diff ':(glob)**/foo'
> 
> Maybe I'm missing something, but if you want to find all *.jpg isn't
> that just:
> 
>     git diff '*.jpg'
> 
> ?

Right, actually I misremembered; it was all '.gitignore' files.

If I do '*.gitignore' that matches all the files, but also any
$x.gitignore files. If I want only '.gitignore' files I need
':(glob)**/.gitignore'.

Cheers.

-- 
Felipe Contreras



[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