From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.help Subject: Re: Eval elisp file automatically Date: Mon, 31 Jan 2011 11:20:31 -0500 Organization: A noiseless patient Spider Message-ID: References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1296492936 10369 80.91.229.12 (31 Jan 2011 16:55:36 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 31 Jan 2011 16:55:36 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Mon Jan 31 17:55:32 2011 Return-path: Envelope-to: geh-help-gnu-emacs@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 1Pjx2K-0000yU-AK for geh-help-gnu-emacs@m.gmane.org; Mon, 31 Jan 2011 17:55:32 +0100 Original-Received: from localhost ([127.0.0.1]:36063 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Pjx2J-0006Ci-Go for geh-help-gnu-emacs@m.gmane.org; Mon, 31 Jan 2011 11:55:31 -0500 Original-Path: usenet.stanford.edu!news.tele.dk!news.tele.dk!small.news.tele.dk!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsfeed.straub-nv.de!eternal-september.org!feeder.eternal-september.org!.POSTED!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 25 Injection-Info: mx02.eternal-september.org; posting-host="xK1PaR9QACCMJMb7vrAh2Q"; logging-data="5008"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18cc/s2+kQBYajsS2x5656u" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) Cancel-Lock: sha1:7c53KMpcsG5m21zEtFiKqFtm0z0= sha1:kuq2e8FpG7FYBN0LhYFo3SIe1dA= Original-Xref: usenet.stanford.edu gnu.emacs.help:184721 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:78880 Archived-At: > I have some functions and variables which I only need in one particular > directory. We have .dir-locals.el for that. Not sure if it'll be sufficient, since you don't give much details. > Another cool thing would be to reset to the defaut value the variables > when I'm not, but it's not really necessary... I have no idea what you mean by "when I'm not": Emacs has many buffers (and windows) so you may have some buffers visiting files in that directory and others visiting files in other directories. In that case would you want your functions to be loaded? Also you talk about restting variables, which implies you're talking not about new variables but about changing the value of existing variables, in which case you probably don't ant to set them globally (which would affect all buffers, including the ones that are visiting files in other directories), but instead you want to set them buffer-locally, i.e. have different values in the buffers that visit this directory than in other buffers (which is what would happen with .dir-locals.el, for example). Stefan