[ESS] Permanently set working directoty
Gregor Gorjanc
gregor.gorjanc at bfro.uni-lj.si
Mon Aug 21 13:02:41 CEST 2006
> Stephen Eglen wrote:
>> Gregor Gorjanc writes:
>> > Hello!
>> >
>> > Is it possible to permanently set working directory for R session in
>> > ESS? I am a bit annoyed with question at R session start as I always
>> > want to start in my home.
>>
>> hi,
>> try looking at the doc for the following two variables:
>> (setq ess-ask-for-ess-directory nil)
>> (setq ess-directory nil)
>>
>> Stephen
Thank you Stephen. The following works for me.
(setq ess-ask-for-ess-directory nil)
(setq ess-directory "~/")
Martin Maechler wrote:
>>>>>> "Gregor" == Gregor Gorjanc <gregor.gorjanc at bfro.uni-lj.si>
>>>>>> on Sun, 20 Aug 2006 18:43:03 +0200 writes:
[snip]
> Very short answer: Yes, RTFM!
>
> Longer answer:
>
> Yes it is easily possible, and we have documented it.
>
> How much have you tried to find the answer in the ESS manual?
> [This question is not rethoric: We have acknowledged that the
> manual has been in a relatively bad shape several years ago.
> OTOH, several of my ESS-core colleagues have spent many hours
> on improving the ESS manual ... ]
Actually I have done some RTFM and found section "3.5 Changing the
startup actions", where this is described but I had problems since
manual says
"If you do not wish ESS to prompt for a starting directory when starting
a new process, set the variable `ess-ask-for-ess-directory' to `nil'.
In this case, the value of the variable `ess-directory' is used as the
starting directory. The default value for this variable is your home
directory."
However, when I set the variable `ess-ask-for-ess-directory' to `nil' R
session starts in directory of last visited file. Say I have opened file
from "/some/where/on/my/disk" and when I fire M-x R, R starts in
"/some/where/on/my/disk" and not from my home directory. Did I do
anything wrong or is my reading of manual bad. However, as already noted
above manual setting of `ess-directory' variable solves this problem.
Perhaps manual should be modified according to this?
Thank you very much for providing such a great interface!
--
Lep pozdrav / With regards,
Gregor Gorjanc
----------------------------------------------------------------------
University of Ljubljana PhD student
Biotechnical Faculty
Zootechnical Department URI: http://www.bfro.uni-lj.si/MR/ggorjan
Groblje 3 mail: gregor.gorjanc <at> bfro.uni-lj.si
SI-1230 Domzale tel: +386 (0)1 72 17 861
Slovenia, Europe fax: +386 (0)1 72 17 888
----------------------------------------------------------------------
"One must learn by doing the thing; for though you think you know it,
you have no certainty until you try." Sophocles ~ 450 B.C.
More information about the ESS-help
mailing list