Subject: Re: bug#39452: [PATCH] vc-git-state fails for filenames with wildcards

From: Noam Postavsky <[email-masked]>
Date: Fri, 07 Feb 2020 09:43:51 -0500

Dmitry Gutov <[email-masked]> writes:

> It's not so simple. FILE already goes through call-process. But Git
> expects a pathspec, not just a file name. So if it's a glob, it is
> expanded.

You can pass --literal-pathspecs to tell git not to expand.  Magit does
this.  But there is a downside due to the way git implements it, which
is by setting an environment variable: it affects all subprocesses git
calls, including git-hook scripts which tends to trip people up.