Subject: Re: bug#71762: `(project-files (project-current))` with `project-vc-extra-root-markers` doesn't work on Windows.

From: Dmitry Gutov <[email-masked]>
Date: Tue, 25 Jun 2024 16:29:50 +0300

On 25/06/2024 00:35, Siyuan Chen wrote:
> 
> Is it possible to use more portable code? For example, 
> `directory-files-recursively`? Otherwise NTEmacs users will have to 
> install CYGWIN or MSYS2.

There are also GNU tools available for download separately, e.g. see the 
ezwinports project.

I'm wary of using directory-files-recursively - because the performance 
can be much different. While right now you see the error and are thus 
encouraged to fix it by installing an extra program or two, in the other 
case the user would just see poor performance (given a large enough 
project) and perhaps some reduced features wrt filtering. And might not 
realize that it's not how the feature is supposed to work.

Also note that 'find.exe' is only required when you have a project 
that's outside of any Git repositories.

> P.s. I have used Projectile before, which allows you to place a 
> .projectile file in `myproject` and everything was OK on Windows. Also 
> if I focus on a git folder e.g. `subproject1` in the example above, the 
> `project-files` also works well.

Projectile has some different tradeoffs, e.g. you might have to reset 
the file cache manually in the above setup. It also has several indexing 
methods to choose from, each with pros and cons.