From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: feature/package-vc has been merged Date: Mon, 07 Nov 2022 19:07:43 +0200 Message-ID: <8335auzo9s.fsf@gnu.org> References: <164484721900.31751.1453162457552427931@vcs2.savannah.gnu.org> <878rkxgpms.fsf@posteo.net> <87sfiyk3a2.fsf_-_@posteo.net> <838rkp4ptj.fsf@gnu.org> <87zgd58i7y.fsf@posteo.net> <83k0492u5i.fsf@gnu.org> <87fsew8g18.fsf@posteo.net> <83mt941cyd.fsf@gnu.org> <87fsewp0ec.fsf@posteo.net> <837d0814c9.fsf@gnu.org> <878rkooz1o.fsf@posteo.net> <831qqg1306.fsf@gnu.org> <874jvcowzm.fsf@posteo.net> <83y1soypvx.fsf@gnu.org> <87y1song5x.fsf@posteo.net> <83v8nsyof7.fsf@gnu.org> <87leoond7l.fsf@posteo.net> <83r0yfzz01.fsf@gnu.org> <87bkpjyx3p.fsf@posteo.net> <83bkpjynmj.fsf@gnu.org> <87iljqya44.fsf@posteo.net> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="3204"; mail-complaints-to="usenet@ciao.gmane.io" Cc: monnier@iro.umontreal.ca, rms@gnu.org, emacs-devel@gnu.org To: Philip Kaludercic Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Mon Nov 07 18:08:49 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 1os5c8-0000dJ-K9 for ged-emacs-devel@m.gmane-mx.org; Mon, 07 Nov 2022 18:08:48 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1os5bO-0003pl-TJ; Mon, 07 Nov 2022 12:08:04 -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 1os5bM-0003oj-7X for emacs-devel@gnu.org; Mon, 07 Nov 2022 12:08:00 -0500 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1os5bL-0005Fn-BW; Mon, 07 Nov 2022 12:07:59 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=jL+h9GfF2UyYw7APTSSauxFJLgAi6bNTHz/TZZ1hn0o=; b=rAB5jBQdgrIU dwZre0ttyUqTGcN/1MO0mDU5nQxQ8J5YwjTW66munHJO6h4dXAttvGi6zZmVrqeiyD/WnxoO5+cUM GgK3sU5qeIs6lcbHXUAz+fHontJGJLKBc6igNuo3Qp0yv1hEdV/8WR+Bdad0NF4qnKsDmdOO0JALM +Sn4BYFd/qXNRcgv4wfLexSdMXwmdbS3cVgj3lx6fVHjjVnYGZuChlJMpwYSJ+bLBNsu5GKl73Qsk UU19RvmvAern9jvBWb36eT5Tip8ybbFMQ4gy/fdzoDZZ8GCT9Lvf3jtizC3Bj2p9QVFio/tVc50V0 LSPmY8uU9QxPLDqbUBNgzg==; Original-Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1os5bK-0006XA-5Z; Mon, 07 Nov 2022 12:07:58 -0500 In-Reply-To: <87iljqya44.fsf@posteo.net> (message from Philip Kaludercic on Mon, 07 Nov 2022 16:58:51 +0000) 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:299298 Archived-At: > From: Philip Kaludercic > Cc: monnier@iro.umontreal.ca, rms@gnu.org, emacs-devel@gnu.org > Date: Mon, 07 Nov 2022 16:58:51 +0000 > > Eli Zaretskii writes: > > >> >> > And if you think many do, why not clone the repository directly into > >> >> > ~/.emacs.d/elpa/? > >> >> > >> >> Because that won't take care of scraping for autoloads, byte > >> >> compilation and installing missing dependencies. > >> > > >> > I don't see why. Please elaborate how having the repository inside > >> > ~/.emacs.d gets in the way of these activities. > >> > >> It doesn't get in the way, the issue just is that if you were to just > >> clone a package right into .emacs.d, you would still have to do all > >> these steps individually and manually. > > > > Which steps are those, and why do we have to do it manually? > > Let us assume `default-directory' is (locate-user-emacs-file "elpa"). > If I run "M-! git clone https://some.git.host.com/path/to/repo/foo.git", > then I'll just have a directory called "foo", right? If I want to byte > compile the files I'd e.g. have to open foo in Dired, mark all Emacs > Lisp files, byte compile them, then run something like > `make-directory-autoloads' myself. Then I'd have to find the main file, > check the dependency list and run M-x package-install on every one that > is missing, again one-by-one. > > You don't have to do this for `package-install', because it invokes > `package-unpack' that takes care of those details. As > package-vc-install doesn't use prepared tarballs, the equivalent process > is a bit different (thus we have `package-vc-unpack'), but the intention > is the same. Bundle all the repetitive task into a single command. OK, but my question was why all of this gets magically done when you clone the repository outside ~/.emacs.d/elpa, but does not get done when you clone it inside? I thought this is what you were alluding to when I asked why not clone into ~/.emacs.d. > > (if (fboundp 'normal-top-level-add-subdirs-to-load-path) > > (normal-top-level-add-subdirs-to-load-path)) > > > > Example of directories which need this is the site-lisp directory. > > I was not familiar with this function. > > > Why cannot we do something like this in this case? > > I would have to try this out, but my worry is that in some cases this > could add too many non-lisp directories. The function can be easily extended to only add directories in which we have *.el files. > It still seems more elegant to encode what the lisp directory is in the > package description. You consider manual configuration of a package to be more elegant than automatically finding the directories to put on load-path?