emacs-devel
[Top][All Lists]
Advanced

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

Re: Subprojects in project.el


From: Dmitry Gutov
Subject: Re: Subprojects in project.el
Date: Tue, 29 Nov 2022 20:40:36 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.4.2

On 29/11/2022 11:56, João Távora wrote:
Dmitry Gutov <dgutov@yandex.ru> writes:

But I'd be happy to find out that 98% of our users' cases can be
handled with markers.

I think you'll begin to lose that bet right here in the Emacs repo.
Take the doc/ directory where Emacs's manuals live.  It's pretty
reasonable to consider a non-programmer (or non-Elisp) contributor
working on that directory almost exclusively, perhaps as a proof-reader.

Setting aside the artificial nature of this example, they could add "lispintro" or "lispref" to project-vc-extra-root-markers and have that nested project recognized.

As long as the directory contains at least some unique (in the scope of the containing project) file or directory, the marker-based approach can work fine.

That person would like C-x p f, C-x p g, etc to operate on the /doc
hierarchy almost always.  For example to escape the enormous amount of
grep matches in the Changelog files.  Occasionally, that person might
want to grep the super-project (Emacs itself) or run a compilation
command from there, but that would be infrequent.

Sounds fine to me.

Now, using marker files to mark doc/ as a subproject is not only
impossible (there are none) and also useless.

Marker files _are_ useful in e.g. large Javascript monorepos where a lot
of NPM packages live.  These are frequently added, removed, reshuffled.
There, looking for `package.json` to designate subprojects makes a lot
of sense, this is beyond question IMO.  But that doesn't make the case I
describe above an exotic exception in any way.

I don't know how many people actually intend to do what you described, though. But it seems workable just the same.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]