From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Phil Sainty Newsgroups: gmane.emacs.devel Subject: Re: Eglot, project.el, and python virtual environments Date: Fri, 18 Nov 2022 15:38:34 +1300 Message-ID: <4cc918a053771a5e1c440cb4b458f3ed@webmail.orcon.net.nz> References: <87zgcq68zp.fsf@ericabrahamsen.net> <878rkale3l.fsf@dfreeman.email> <87v8nezf2k.fsf@ericabrahamsen.net> <87o7t5k7sv.fsf@dfreeman.email> <86mt8p4221.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="12053"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Orcon Webmail Cc: emacs-devel@gnu.org To: Tim Cross Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Fri Nov 18 03:40:34 2022 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1ovrIw-000309-Mq for ged-emacs-devel@m.gmane-mx.org; Fri, 18 Nov 2022 03:40:34 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ovrHB-00016T-EV; Thu, 17 Nov 2022 21:38:45 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ovrH9-00016F-PU for emacs-devel@gnu.org; Thu, 17 Nov 2022 21:38:43 -0500 Original-Received: from smtp-1.orcon.net.nz ([60.234.4.34]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ovrH8-000559-32 for emacs-devel@gnu.org; Thu, 17 Nov 2022 21:38:43 -0500 Original-Received: from [10.253.37.70] (port=41816 helo=webmail.orcon.net.nz) by smtp-1.orcon.net.nz with esmtpa (Exim 4.90_1) (envelope-from ) id 1ovrH0-0004D3-Li; Fri, 18 Nov 2022 15:38:35 +1300 Original-Received: from ip-180-148-114-34.kinect.net.nz ([180.148.114.34]) via [10.253.37.253] by webmail.orcon.net.nz with HTTP (HTTP/1.1 POST); Fri, 18 Nov 2022 15:38:34 +1300 In-Reply-To: <86mt8p4221.fsf@gmail.com> X-Sender: psainty@orcon.net.nz X-GeoIP: -- Received-SPF: pass client-ip=60.234.4.34; envelope-from=psainty@orcon.net.nz; helo=smtp-1.orcon.net.nz X-Spam_score_int: -25 X-Spam_score: -2.6 X-Spam_bar: -- X-Spam_report: (-2.6 / 5.0 requ) BAYES_00=-1.9, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:300078 Archived-At: On 2022-11-18 11:21, Tim Cross wrote: > Is this something which should be addressed at the eglot level or at > the > project level? It seems to me that what you really have here is a main > project which consists of a number of sub-projects and that it could be > beneficial more generally if you could more easily isolate out the > sub-projects (not just for eglot, but possibly for other tools as well) > at the project.el layer rather than the eglot layer. This could mean > the > user has to be more involved in defining the project and sub-project > structure/relationships, but that may be reasonable when you have more > complex project structure? > > I guess my question here is whether the focus should be on enhancing > project.el rather than modifying/enhancing eglot.el to handle this use > case? It seems to me that while project.el could acquire the notion of sub-projects, the *meaning* of a sub-project would be entirely specific to the tool which needed it (eglot in this case). And if you had multiple tools which each wanted some kind of sub-project, you might find that some of the sub-projects were overlapping others, depending on the needs of the tools which each one was related to. Still, if eglot could ask project.el for "the nearest sub-project defined for 'eglot' usage, if any, and otherwise the main project" and project.el had been told that for the project at /path/to/proj there was an 'eglot' sub-project at /path/to/proj/subdir/foo, then that could be useful. So project.el could provide an API for defining and returning sub-projects, but it would be up to eglot (or other tools) to cause such sub-projects to have any kind of effect, and it would be up to the end-user to define their 'eglot' sub-projects in the first place.