From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: user-controlled load-path extension: load-dir Date: Tue, 08 Mar 2011 15:59:51 -0500 Message-ID: References: <87ei6mz24h.fsf@lifelogs.com> <20110306072147.GA11067@event-horizon.homenet> <871v2i525h.fsf@lifelogs.com> <87oc5lx607.fsf@lifelogs.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1299618007 28094 80.91.229.12 (8 Mar 2011 21:00:07 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 8 Mar 2011 21:00:07 +0000 (UTC) Cc: emacs-devel@gnu.org To: Ted Zlatanov Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Mar 08 22:00:02 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 1Px40g-0004x7-5y for ged-emacs-devel@m.gmane.org; Tue, 08 Mar 2011 22:00:02 +0100 Original-Received: from localhost ([127.0.0.1]:56060 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Px40f-0005Gx-FD for ged-emacs-devel@m.gmane.org; Tue, 08 Mar 2011 16:00:01 -0500 Original-Received: from [140.186.70.92] (port=37933 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Px40a-0005Gr-21 for emacs-devel@gnu.org; Tue, 08 Mar 2011 15:59:57 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Px40Y-0006rZ-SY for emacs-devel@gnu.org; Tue, 08 Mar 2011 15:59:56 -0500 Original-Received: from chene.dit.umontreal.ca ([132.204.246.20]:48422) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Px40Y-0006rV-L2 for emacs-devel@gnu.org; Tue, 08 Mar 2011 15:59:54 -0500 Original-Received: from faina.iro.umontreal.ca (lechon.iro.umontreal.ca [132.204.27.242]) by chene.dit.umontreal.ca (8.14.1/8.14.1) with ESMTP id p28L0nEf011112; Tue, 8 Mar 2011 16:00:49 -0500 Original-Received: by faina.iro.umontreal.ca (Postfix, from userid 20848) id E3BE3B426D; Tue, 8 Mar 2011 15:59:51 -0500 (EST) In-Reply-To: <87oc5lx607.fsf@lifelogs.com> (Ted Zlatanov's message of "Tue, 08 Mar 2011 04:26:32 -0600") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) X-NAI-Spam-Score: 0 X-NAI-Spam-Rules: 1 Rules triggered RV3735=0 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-Received-From: 132.204.246.20 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:136919 Archived-At: >>> I think this proposal is really about code snippets that people would >>> otherwise just cut and paste into their .emacs file. The average >>> user's .emacs often winds up containing mostly code they found >>> somewhere and use without really understanding it. Dropping each >>> snippit in its own file would be a big help if the user ever did need >>> to debug some problem with his init, or if he decided one day to >>> actually learn elisp. SM> I'm far from convinced it's better for people to drop random chunks of SM> configuration into separate files rather than all in the .emacs file. > It's not "better," it's what people already do. I must be missing something. I see two different things on the web: packages on the one hand and Elisp configuration chunks on the other. The first come in files you can download, the other comes in
...
elements in HTML pages which you can copy&paste. My claim is that the first can be better handled by package.el or themes and the other works just fine in .emacs. > Emacs would just make it easier than the current situation, which is > to drop a file plus edit the .emacs every time a file is added or > deleted. If you drop the file with package.el you don't need to edit the .emacs correspondingly. > want to load them modularly. So I put them in the load-dir. Do I have > to make 8 packages? And every time I update one of those files, do I > have to repackage it with a new version? That seems workable but > tedious compared to the code proposed by Ben Key and Evans Winner. If you're really talking about configuration code rather than packages, then I tend to assume that people whose .emacs is so large as to need modularization can figure out which kind of modularization they want and implement (or copy&paste) the corresponding loop to load the various files. I'm not even sure why you'd want to "modularize" in this way: my .emacs was fairly large but splitting it into separate files never seemed like a good way to help, since I'd then have to figure out how to make C-s and M-/ find matches in neighboring files. Instead I "split" it with outline-minor-mode. > If you're against including the load-dir in the core and enabling it by > default, how about making it a GNU ELPA package so it's easily > installable? Such a package would be perfectly acceptable, yes. Stefan