From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Barry Margolin Newsgroups: gmane.emacs.help Subject: Re: How to change default "insert file" path /tmp to home directory? Date: Mon, 13 May 2013 17:48:54 -0400 Organization: A noiseless patient Spider Message-ID: References: <877gj6sg4g.fsf@kuiper.lan.informatimago.com> NNTP-Posting-Host: plane.gmane.org X-Trace: ger.gmane.org 1368489486 675 80.91.229.3 (13 May 2013 23:58:06 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 13 May 2013 23:58:06 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue May 14 01:58:05 2013 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Uc2d2-0000xs-GI for geh-help-gnu-emacs@m.gmane.org; Tue, 14 May 2013 01:58:04 +0200 Original-Received: from localhost ([::1]:54129 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Uc2d2-000332-7Y for geh-help-gnu-emacs@m.gmane.org; Mon, 13 May 2013 19:58:04 -0400 Original-Path: usenet.stanford.edu!news.kjsl.com!feeder.erje.net!eu.feeder.erje.net!eternal-september.org!feeder.eternal-september.org!mx05.eternal-september.org!barmar.motzarella.org!.POSTED!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 39 Injection-Info: barmar.motzarella.org; posting-host="2be9e9f5dd9af768b8861af71b85fc28"; logging-data="19644"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/oqSqaWO0my//1KwtzATVj" User-Agent: MT-NewsWatcher/3.5.3b3 (Intel Mac OS X) Cancel-Lock: sha1:UP/b3k9KmaeMDUKrz6zPzBQuY90= Original-Xref: usenet.stanford.edu gnu.emacs.help:198462 X-Mailman-Approved-At: Mon, 13 May 2013 19:57:51 -0400 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:90731 Archived-At: In article , gerlach wrote: > Am 10.05.2013 23:02, schrieb Pascal J. Bourguignon: > > gerlach writes: > > > >> Hi, > >> I googl'ed a lot and didn't find it: how can I change the default > >> "insert path" (ctrl-x i) from /tmp to e.g. /home/gerlach ? > > > > M-: (setq default-directory "/home/gerlach/") RET > > > > > > i state today that its any longer working! Default directory is /tmp > once again. At least in Why? > > my /home/gerlach/.emacs > (setq fill-column 50) > (add-hook 'before-save-hook 'delete-trailing-whitespace) > (setq default-directory "/home/gerlach/") > > > BTW: (setq fill-column 50) is ignored. Even if I insert 20 instead of > 50. Why? fill-column is a buffer-local variable. Use setq-default to set the default value for new buffers. And as I mentioned in another reply, default-directory is also buffer-local. However, it doesn't help much to set its default value, because it's automatically changed to the directory containing the file you're editing. You can use setq-default, but that will only work for buffers that aren't editing files. -- Barry Margolin, barmar@alum.mit.edu Arlington, MA *** PLEASE post questions in newsgroups, not directly to me ***