Re: [PATCH/alternative/raw and rough] setup.c: denote repo wide pathspecs by ':'

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

 



On 03/02/2011 11:53 AM, Junio C Hamano wrote:
> Michael J Gruber <git@xxxxxxxxxxxxxxxxxxxx> writes:
>> [*] I keep forgetting that some people may have files whose names begin
>> with ":". They are ambiguous now already with "treeish pathspec"
>> commands, but not with "pathspec" commands. The latter would change.
> Just to make sure I understand that they have easy workarounds:
>
>  - If you have a path foo/:bar, you can say
>
>    git log master -- foo/:bar
>
>    because ':' signals the magic and gets stripped only when it is at the
>    beginning (i.e. not affecting foo/:bar); and
>
>  - For :boz at the root level, you can say
>
>    git log master -- '\:boz'
>
>    because the backslash in '\:boz' makes the colon not at the beginning and
>    the glob match sees '\:boz' and then matches '\:' with literal ':' at the
>    beginning of the pathname ":boz".

Easy workaround, maybe, but still a potential problem for unsuspecting
scripts.

  - I think this fails in a directory with :foo.c

    git log master -- *.c


  - Would this work, though?

    git log master -- "*.c"

Phil

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[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]