Re: Bug or unexpected behaviour in git show <rev>:a\b

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

 



Jeff King <peff@xxxxxxxx> writes:

> So everything is working as designed, or at least explainable. But I
> think there is some room for improvement. A backslash that isn't
> followed by a glob meta-character _is_ still a meta character (your
> "a\b" would be globbing for "ab"). But it's useless enough that I think
> it shouldn't be enough to trigger the "oh, you probably meant this as a
> pathspec" DWIM rule.

This sounds sensible.

> We _could_ also say "even though this could technically be a pathspec
> because of its metacharacter, it looks vaguely enough like a
> path-in-tree revision that we shouldn't guess". That I'm less
> comfortable with, just because it makes the heuristics even more
> magical.

Not just it becomes more magical, I am afraid that the code to
implement such a heuristics would be fragile and become a source of
unnecessary bugs.  Let's not go there.

I should learn to use "working as designed or at least explainable"
more often in my responses, by the way.  That's quite a useful and
good phrase ;-)




[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