[ESS] Ess-source-directory in windows

Liaw, Andy andy_liaw at merck.com
Mon Jun 20 19:21:14 CEST 2005


Thanks, Tim, but I don't think that will solve Matt's problem.  If I'm not
mistaken, what Matt wants is to have ess-source-directory set to the
"R-source" subdirectory of the working directory for the iESS process.
E.g., if I start an R process in, say, c:/project1, then c-c c-d allows me
to dump an object to a file in c:/project1/R-source.  However, if I then do
c-c c-l in that buffer, I get the error that Matt mentioned (seems like
directory separators are somehow dropped).  This works correctly in GNU
Emacs.  The only setup where we found the problem is XEmacs on Windows XP.

Cheers,
Andy

> From: Tim Hesterberg 
> 
> One idea is to use absolute paths, and specify them differently
> for each machine.
> 
> 
> Early in my .emacs, I define some variables that indicate which
> system I'm working on:
> 
> (if (or (equal system-name "TIMH-2K")
> 	(equal system-name "HESTERBERG-XP")) (prog1
>   (setq atUnix nil)
>   (setq atWorkPC t)
> ))
> (if (equal system-name "HESTERBERGLAPTO") (prog1
>   (setq atUnix nil)
>   (setq atHome t)
> ))
> (setq atPC (or atHome atWorkPC))  ; true if either atHome or atWorkPC
> 
> 
> The later I do things like this:
> 
> (if atUnix
>     (load-file "/homes/timh/local/ess-5.1.24/lisp/ess-site.el")
>   (if atHome			     
>     (load-file "c:/emacs/ess-5.1.24/lisp/ess-site.el")
>     (load-file "d:/emacs/ess-5.2.5/lisp/ess-site.el")
>     ))
> 
> I'm using gnu emacs.
> Tim Hesterberg
> 
> -----Original Message-----
> From:	Liaw, Andy [mailto:andy_liaw at merck.com]
> Sent:	Mon 6/20/2005 6:43 AM
> To:	Wiener, Matthew; ESS-help at stat.math.ethz.ch
> Cc:	
> Subject:	Re: [ESS] Ess-source-directory in windows
> Not much help to Matt, perhaps:  On WinXPPro, ESS 5.2.7, GNU 
> Emacs 21.3.1,
> XEmacs 21.4.13, R-2.1.0.  I get similar problem as Matt with 
> XEmacs, but no
> problem with GNU Emacs.
> 
> Andy
> 
> > From: Wiener, Matthew
> > 
> > All --
> > 
> > In both my unix and windows .xemacs files (actually .emacs on 
> > unix), I have
> > the following:
> > 
> > (setq ess-source-directory
> >       (lambda ()
> >         (concat ess-directory "R-source")))
> > 
> > Which allows me to keep my source in a sub-directory of my project
> > directory.
> > 
> > In unix, it works great.  In windows, which I have just 
> > started trying to
> > use, I get errors like the following:
> > 
> > 
> > Error in file(file, "r", encoding = encoding) : 
> > 	unable to open connection
> > In addition: Warning message:
> > cannot open file 'c:R-projects
> > etworkR-source.get.degree.and.dist.stats.R' 
> > 
> > This when my working directory is:
> > > getwd()
> > [1] "c:/R-projects/network"
> > 
> > So it looks to me like the single slashes are getting 
> > clobbered by escape.
> > But if I try to set the working directory with doubled windows-style
> > slashes, getwd() gives me the same thing.  I've looked on the 
> > web site, but
> > have not been able to find a solution (or, perhaps, realize 
> > I've found a
> > solution).
> > 
> > Thanks for any help you can give.
> > 
> > Regards,
> > 
> > Matthew Wiener
> > Applied Computer Science & Mathematics
> > Merck Research Laboratories
> > Rahway, NJ 07065
> > 732-594-5303
> > 
> > ______________________________________________
> > ESS-help at stat.math.ethz.ch mailing list
> > https://stat.ethz.ch/mailman/listinfo/ess-help
> > 
> > --------------------------------------------------------------
> > ----------------
> > Notice:  This e-mail message, together with any attachments, 
> > contains information of Merck & Co., Inc. (One Merck Drive, 
> > Whitehouse Station, New Jersey, USA 08889), and/or its 
> > affiliates (which may be known outside the United States as 
> > Merck Frosst, Merck Sharp & Dohme or MSD and in Japan, as 
> > Banyu) that may be confidential, proprietary copyrighted 
> > and/or legally privileged. It is intended solely for the use 
> > of the individual or entity named on this message.  If you 
> > are not the intended recipient, and have received this 
> > message in error, please notify us immediately by reply 
> > e-mail and then delete it from your system.
> > --------------------------------------------------------------
> > ----------------
> > 
> >
> 
> ______________________________________________
> ESS-help at stat.math.ethz.ch mailing list
> https://stat.ethz.ch/mailman/listinfo/ess-help
> 
> 
> 
> 
>




More information about the ESS-help mailing list