help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Default directory in startup buffer


From: Jarmo Hurri
Subject: Default directory in startup buffer
Date: Fri, 21 Jan 2011 09:53:11 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.2 (gnu/linux)

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? ]

-- 
Jarmo Hurri

Remove all garbage from header email address when replying, or just
use firstname.lastname@syk.fi .


reply via email to

[Prev in Thread] Current Thread [Next in Thread]