From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= Newsgroups: gmane.emacs.devel Subject: Re: Subprojects in project.el Date: Sat, 26 Nov 2022 00:46:18 +0000 Message-ID: <87v8n2sftx.fsf@gmail.com> References: <87zgcq68zp.fsf@ericabrahamsen.net> <877czqtyfy.fsf@dfreeman.email> <87zgcml7g7.fsf@gmail.com> <2ba04533-097a-a1da-ff3f-2c9506fd488e@yandex.ru> <875yf9bbzb.fsf@gmail.com> <87wn7oa0aw.fsf@gmail.com> <7a5b76fd-fb15-8c1e-ea29-bf11f7e0d2ae@yandex.ru> <87bkoya815.fsf@gmail.com> <0024a67d-b8e5-b35c-1b22-82541a170eb3@yandex.ru> <871qptai4d.fsf_-_@gmail.com> <33292672-2a59-ba63-05ab-a7995118a822@yandex.ru> <86pmdb34hb.fsf@mail.linkov.net> <87cz9atx3o.fsf@gmail.com> <029529d0-a846-483b-cb13-67fad54e9b13@yandex.ru> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="9856"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: Juri Linkov , Stefan Monnier , Danny Freeman , Eric Abrahamsen , emacs-devel To: Dmitry Gutov Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sat Nov 26 01:45:48 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 1oyjKF-0002M6-NS for ged-emacs-devel@m.gmane-mx.org; Sat, 26 Nov 2022 01:45:47 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oyjJd-0004vl-Rb; Fri, 25 Nov 2022 19:45:09 -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 1oyjJb-0004vM-Fi for emacs-devel@gnu.org; Fri, 25 Nov 2022 19:45:07 -0500 Original-Received: from mail-wr1-x432.google.com ([2a00:1450:4864:20::432]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oyjJY-0002z5-Iz for emacs-devel@gnu.org; Fri, 25 Nov 2022 19:45:07 -0500 Original-Received: by mail-wr1-x432.google.com with SMTP id g12so8872257wrs.10 for ; Fri, 25 Nov 2022 16:45:04 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:user-agent:message-id:date :references:in-reply-to:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=rrWAiF7khJ+b18kn+o2L5GBkvbf2lE5R9WsWOe1cg8c=; b=SdAupnlsYsOq7Fn9IU4sT+bvfqPzGpMNgtxfmQKPPQGHX43v8gUUbBOL0eRRLc0QnW 15Gfw/rOgxZ49Cs8dwn49nuxCRbvHFGVFcQcydQzcu5lOz030T3twsHC20yIUH99IAAI quvAlghOKoulMS3BlFXdsN5ThMaCGMSxtugpVAP9icGpxZ3fj/jukrUEVKk93FaeRVCl C4MBNR2fhsGKGrQTSFX+8CZJYbZKhS8QcuLCqbqsiVA5icTdyclu/KR9We5NVYwHn4Z4 Afh/okjMf/GeTBaGmqJhzb0neQeBlOG5gVZoKPX/F8RUxzJL5nVxIgtgvrKgMzeg/Vyj XJFA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:user-agent:message-id:date :references:in-reply-to:subject:cc:to:from:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=rrWAiF7khJ+b18kn+o2L5GBkvbf2lE5R9WsWOe1cg8c=; b=lKeineF7XMPOCmmRTJSR2J17Y8JpDRH3CP6YDrSdpbGSt57m9xGuJrKsgMjS293WR5 KofTo7ulKc8OeTb70BSbREX2hqIUum9QED1XSMue4+8rEdk2LRiWdTXj6P2X1H7QJE1Z MWwDbg/UZ/lDqdQfvXdqOYzwQAV9Er6YSO+U4aCstohGzTCtX+ACkbD/qDFQJb8Uya33 Mm8IA0fczYl/b295THdep0dxS0+DSJ+KjXIeH+fMhPd30N21xWLMi0pccVXzWK9iNg7j W9Zojc3XH4vG5JG8OSd4wW8sbx3nF6Vh1YqORn3lVxCjYjdXMQfUqm38yd3M6h9EJcsb OUnQ== X-Gm-Message-State: ANoB5pntt4uqeBmaQwEJn08KW8xnyDnnernyPExpvkBp3Crxdbk0kLid +UL12bW0TLSdzo8pvcvwldYw7fW2acY= X-Google-Smtp-Source: AA0mqf7re33uYEAN++Mh7HkJqwhiK7kpy3+PK7o85sVhHBTfYTOr2fyF5CGeBQpiGBbIsGpvfhSamA== X-Received: by 2002:a5d:554b:0:b0:242:84c:8d2 with SMTP id g11-20020a5d554b000000b00242084c08d2mr3060606wrw.555.1669423502664; Fri, 25 Nov 2022 16:45:02 -0800 (PST) Original-Received: from krug (87-196-72-177.net.novis.pt. [87.196.72.177]) by smtp.gmail.com with ESMTPSA id o5-20020a05600c510500b003b4ff30e566sm17421520wms.3.2022.11.25.16.45.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 25 Nov 2022 16:45:02 -0800 (PST) In-Reply-To: <029529d0-a846-483b-cb13-67fad54e9b13@yandex.ru> (Dmitry Gutov's message of "Sat, 26 Nov 2022 01:58:41 +0200") Received-SPF: pass client-ip=2a00:1450:4864:20::432; envelope-from=joaotavora@gmail.com; helo=mail-wr1-x432.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, 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:300537 Archived-At: Dmitry Gutov writes: > On 26/11/22 01:47, Jo=C3=A3o T=C3=A1vora wrote: >> You can use dir-locals-set-class-variables to variable like the >> hypothetical project-subproject-prefixes to the super-project's root. >> This contains a list of strings or regexps that identify the subprojects >> inside the superproject. I don't see the problem. Elements in >> project-find-functions would be aware of this value and proceed >> accordingly to find the subprojects. > > I don't see the problem in that. > > I just fail to see an advantage either, given that the list of > prefixes would be different between the "super" projects, so the > suggestion to use a class is perplexing. The point of dir-locals-set-class-variables is to set directly-locals "from a distance" when creating an actual .dir-locals.el file isn't feasible or desired. (dir-locals-set-directory-class "~/Source/very-big-project" 'very-big-pro= ject) (dir-locals-set-class-variables 'very-big-project ((nil . (project-find-p= refixes "foo" "bar/baz.*")))) Even if it's a one-use class, there's nothing wrong with that IMO. And chances are you have multiple clones or Git worktrees of the same project, so you may as well make it a two- or three-use class (dir-locals-set-directory-class "~/Source/worktree-2" 'very-big-project) (dir-locals-set-directory-class "~/Source/another-clone" 'very-big-projec= t) Of course if the user is able to AND wants to use .dir-locals.el or marker files, that is fine, too. I personally like the above scheme. Jo=C3=A3o