From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Mario Lassnig Newsgroups: gmane.emacs.help Subject: Re: Default directory in startup buffer Date: Fri, 21 Jan 2011 09:16:12 +0100 Organization: Aioe.org NNTP Server Message-ID: References: Reply-To: mario@lassnig.net NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1295599266 28193 80.91.229.12 (21 Jan 2011 08:41:06 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Fri, 21 Jan 2011 08:41: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 Fri Jan 21 09:41:02 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 1PgCYH-0002SL-Lt for geh-help-gnu-emacs@m.gmane.org; Fri, 21 Jan 2011 09:41:01 +0100 Original-Received: from localhost ([127.0.0.1]:39962 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PgCYH-00065q-2p for geh-help-gnu-emacs@m.gmane.org; Fri, 21 Jan 2011 03:41:01 -0500 Original-Path: usenet.stanford.edu!news.tele.dk!news.tele.dk!small.news.tele.dk!newsfeed.xs4all.nl!newsfeed6.news.xs4all.nl!xs4all!news2.euro.net!feeder.news-service.com!94.75.214.39.MISMATCH!aioe.org!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 60 Original-NNTP-Posting-Host: D53vwQ+X8mXYrakDmdrzeQ.user.speranza.aioe.org Original-X-Complaints-To: abuse@aioe.org X-Notice: Filtered by postfilter v. 0.8.2 User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-GB; rv:1.9.2.13) Gecko/20101207 Thunderbird/3.1.7 Original-Xref: usenet.stanford.edu gnu.emacs.help:184474 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:78637 Archived-At: On 1/21/11 8:53 AM, Jarmo Hurri wrote: > > Greetings. > > I am installing GNU Emacs on a bunch of Windows machines for a group of > students in order for them to be able to run R via ESS. So the students > will just start Emacs and run R in it. I just installed the newest > version of GNU Emacs from emacs-22.3-bin-i386.zip. > > The problem is that the startup screen does not obey > default-directory. Putting the following line in site-startup.el > > (setq default-directory "~/") > > does change the default directory in buffer "*scratch*", but not in > buffer "*GNU Emacs*" I know about the variables inhibit-startup-screen > and inhibit-splash-screen, but I also know these have been intentionally > designed not to work in site-start.el. (Which I find a bit weird even > after reading the justification.) > > The only workaround I was able to invent was to kill the startup buffer > in site-start.el > > (kill-buffer "*GNU Emacs*") > > so now my students' first introduction to GNU Emacs is a completely > empty "*scratch*" buffer and the message > > *GNU Emacs*: no such buffer > > (I also tried to change the buffer at site-start.el, but this does not > work.) I think there should be a better way around this. > > Note that it is _not_ feasible to make the students edit personal > .emacs-files or something like that. Emacs is just a tool here, and it > should not distract from the main theme (programming and statistics). > > [ As a related note, I found it surprising that I had to include the > line > (setq default-directory "~/") > in site-start.el in order to get a reasonable default directory even > in buffer "*scratch*". Should that kind of behaviour be the default in > Emacs? ] > How about this for a clean slate, starting out with a clean scratch-buffer. (setq inhibit-startup-echo-area-message t) (setq inhibit-startup-screen t) (setq initial-scratch-message nil) (kill-buffer "*Messages*") oh, and the scratch buffer does not have a directory, because it's not associated with a file.