From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Dimitri Fontaine Newsgroups: gmane.emacs.devel Subject: Re: user-controlled load-path extension: load-dir Date: Tue, 08 Mar 2011 21:01:18 +0100 Message-ID: References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; format=flowed X-Trace: dough.gmane.org 1299614498 7376 80.91.229.12 (8 Mar 2011 20:01:38 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 8 Mar 2011 20:01:38 +0000 (UTC) Cc: tzz@lifelogs.com, Emacs-devel@gnu.org To: Ben Key Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Mar 08 21:01:31 2011 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Px363-0002f0-3v for ged-emacs-devel@m.gmane.org; Tue, 08 Mar 2011 21:01:31 +0100 Original-Received: from localhost ([127.0.0.1]:45236 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Px362-0004CI-DL for ged-emacs-devel@m.gmane.org; Tue, 08 Mar 2011 15:01:30 -0500 Original-Received: from [140.186.70.92] (port=52567 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Px35x-0004C1-Re for Emacs-devel@gnu.org; Tue, 08 Mar 2011 15:01:26 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Px35w-0002eg-NM for Emacs-devel@gnu.org; Tue, 08 Mar 2011 15:01:25 -0500 Original-Received: from prometheus.naquadah.org ([212.85.154.174]:36959 helo=mx1.naquadah.org) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Px35w-0002eH-FH for Emacs-devel@gnu.org; Tue, 08 Mar 2011 15:01:24 -0500 Original-Received: by mx1.naquadah.org (Postfix, from userid 8) id B2EC05C0F3; Tue, 8 Mar 2011 21:01:22 +0100 (CET) Original-Received: from DimIMac.local (89-159-58-5.rev.dartybox.com [89.159.58.5]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.naquadah.org (Postfix) with ESMTPSA id 4EEA45C0E4; Tue, 8 Mar 2011 21:01:20 +0100 (CET) Original-Received: by DimIMac.local (Postfix, from userid 501) id D32B61B2D8A3; Tue, 8 Mar 2011 21:01:18 +0100 (CET) User-Mail-Address: dim@tapoueh.org In-Reply-To: (Ben Key's message of "Tue, 8 Mar 2011 12:49:37 -0600") User-Agent: Gnus/5.110014 (No Gnus v0.14) Emacs/24.0.50 (darwin) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-Received-From: 212.85.154.174 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:136915 Archived-At: Ben Key writes: > I am more than willing to continue development of this file into > an Emacs package that can be included in ELPA. This would make > it possible for this useful feature to be made readily available > to those who want to use it without including it in Emacs > itself. In my opinion, the biggest value by far of such a feature is to be able to depend on `user-load-dir' with no active collaboration of the user. So please consider including in Emacs, not as an additional package. Really the goal is to simplify as much as possible the steps required to install a new elisp file as a user. See how it goes each time (and that's only too often each day) on the help channel: 20:55 ,install 20:55 install -- [0] To install a .el, save it to, say ~/elisp 20:55 [1] add to the beginning of ~/.emacs: (add-to-list 'load-path "~/elisp"), ..[Type ,more] 20:55 ,m 20:56 [2] now FOLLOW THE INSTALLATION INSTRUCTIONS IN THE FILE, typically adding (require ') to the end of ~/.emacs, 20:56 [3] see http://www.emacswiki.org/cgi-bin/wiki.pl?LoadPath, ..[Type ,more] 20:56 ,m 20:56 [4] the site-wide emacs extension directory is usually `/usr/local/share/emacs/site-lisp', 20:56 [5] see autoload With this new facility, we could say to newbies to just save the .el in ~/.emacs.d/load.d and do M-x load-user-files, or even M-x load-new-user-files. And of course we could bootstrap external scripts much more easily: if we take el-get as an example, the user would never have to worry about the load-path any more. Ever. Also I think that `user-load-dir' should default to "~/.emacs.d/load.d/". I have no particular opinion on the autoloading facility that Julien requires, because it seems to me that as soon as the `user-load-dir' is there, it's easy to provide for a snippet that allow support for "~/.emacs.d/autoload.d", whereas I don't see how to go the other route. Regards, -- dim