From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: feature/package+vc 04c4c578c7 3/4: Allow for packages to be installed directly from VCS Date: Wed, 16 Feb 2022 21:56:19 -0500 Message-ID: References: <164484721900.31751.1453162457552427931@vcs2.savannah.gnu.org> <20220214140020.04438C00891@vcs2.savannah.gnu.org> <87bkz9tbcj.fsf@posteo.net> <87o839ypx6.fsf@posteo.net> <87mtisnjcb.fsf@posteo.net> <87sfsizaub.fsf@posteo.net> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="20922"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) Cc: emacs-devel@gnu.org To: Philip Kaludercic Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Thu Feb 17 03:58:21 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 1nKWzs-0005EX-74 for ged-emacs-devel@m.gmane-mx.org; Thu, 17 Feb 2022 03:58:20 +0100 Original-Received: from localhost ([::1]:45846 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nKWzq-00018a-Ma for ged-emacs-devel@m.gmane-mx.org; Wed, 16 Feb 2022 21:58:18 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:53566) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nKWyF-0000Pn-Kt for emacs-devel@gnu.org; Wed, 16 Feb 2022 21:56:39 -0500 Original-Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]:53231) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nKWyC-0005PN-1O for emacs-devel@gnu.org; Wed, 16 Feb 2022 21:56:38 -0500 Original-Received: from pmg1.iro.umontreal.ca (localhost.localdomain [127.0.0.1]) by pmg1.iro.umontreal.ca (Proxmox) with ESMTP id C658A1001AC; Wed, 16 Feb 2022 21:56:32 -0500 (EST) Original-Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg1.iro.umontreal.ca (Proxmox) with ESMTP id D3E8A1000A3; Wed, 16 Feb 2022 21:56:26 -0500 (EST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1645066586; bh=nz02fq0zGwGBJpxVzi35FcNrfcEINNhcjRffhUQb6cA=; h=From:To:Cc:Subject:References:Date:In-Reply-To:From; b=Mc3LhH0Uu7zZoaYq2Y072T+cAJqMwNUzzB9epYOqXu48oz+4zWVyBOjt664Lwd68V sUPwE9d++q0VZ5GL2uGBXOOu92+bZzFqTaCPJ+iOMHpxgyd+2VKaHR9/udbD6WAMUb YVBPbuxCPR2zhczcDRSYOCQTow2rVkhIdKwZk58OhX7VvpuNPsn2j96Y4eeV+sYhVW zaNLZBsDyMY60kYg6vaJycxNCpC1CyIpGkH6pNrH0GkK4lUvqVqa8FTkwaDh9z0Eb0 IhxDC/WSVoQyUKEyFgHLp0IoaoYOnWSsjwCd1j9bcnzp/pILURZLX8QyGPGmEkSDGs /WybyVcmoHcAA== Original-Received: from pastel (unknown [45.72.237.157]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id 82D1712033F; Wed, 16 Feb 2022 21:56:26 -0500 (EST) In-Reply-To: <87sfsizaub.fsf@posteo.net> (Philip Kaludercic's message of "Wed, 16 Feb 2022 22:49:00 +0000") Received-SPF: pass client-ip=132.204.25.50; envelope-from=monnier@iro.umontreal.ca; helo=mailscanner.iro.umontreal.ca X-Spam_score_int: -42 X-Spam_score: -4.3 X-Spam_bar: ---- X-Spam_report: (-4.3 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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" Xref: news.gmane.io gmane.emacs.devel:286409 Archived-At: >>>> I'm sorry, I don't understand what you're saying here. Who&how does >>>> "just clone a project into elpa/devel" and what do you mean by "elpa/devel"? >>> >>> What I meant was that all directories in ~/.emacs.d/elpa/devel could be >>> automatically detected and loaded. >> >> That's already the case if `~/.emacs.d/elpa/devel` is in >> `package-directory-list`, so I don't understand how that relates to what >> we're discussing. > > Unless I am mistaken, `package--make-autoloads-and-stuff' is currently > only invoked by `package-unpack', that in turn is only called by the > `package-install-from-*' functions. Am I missing something, or how > would the autoload file be generated if I just place a repository into > ~/.emacs.d/elpa/devel? I don't think we should spend too much time trying to support the case where a user only does `git clone` and expects Emacs to notice the new package and set it up magically. Instead, I'd expect `package-activate-all` to warn the user about a missing `-pkg.el` when collecting the available packages and about a missing `-autoloads.el` file when trying to activate a given package. Then the user can use some `package--refresh` or somesuch to (re)create those files (and (re)compile the `.el` files along the way and (re)generate the docs, ...). > Say a repository consists of only an init.el, and a few submoduled git > repositories under /elpa/devel/. These wouldn't include the -pkg.el or > -autoload.el files, so they should be generated as soon as necessary. Let those users write specific code for that if they so wish. Generating the `-pkg.el` file as well as the `-autoloads.el` cannot be done fully automatically in all cases. More specifically it may require the package's spec to find the `:main-file` and other such things. I don't think we should aim for that level of automation yet. Stefan