Re: [PATCH 1/4] fsmonitor: Watch, and ask about, the top of the repo, not the CWD

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

 



Hi Alex,

On Wed, 25 Oct 2017, Alex Vandiver wrote:

> On Fri, 20 Oct 2017, Johannes Schindelin wrote:
> > This is super expensive, as it means a full-blown new process instead of
> > just a simple environment variable expansion.
> > 
> > The idea behind using `PWD` instead was that Git will already have done
> > all of the work of figuring out the top-level directory and switched to
> > there before calling the fsmonitor hook.
> 
> I'm not seeing that PWD has been at all altered.

No, PWD is not altered.

But a simple environment variable expansion (fast) was replaced by
spawning to `git rev-parse --show-top-level` (slow, ~60ms on Windows).

*That* is expensive.

Ciao,
Johannes



[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