[ESS] Problem with preview of Rd files
    Ben Bolker 
    bbolker at gmail.com
       
    Wed Feb  1 02:54:17 CET 2012
    
    
  
Martin Fink <martinfink <at> gmx.at> writes:
> Stephen Eglen <S.J.Eglen <at> damtp.cam.ac.uk> writes:
> 
> > A couple of things to check.  
> > 1. when in the .Rd buffer, what does the following give?
> >   C-h v buffer-file-name
> > 
> > 2. From a shell, can you try something like 
> >    R CMD Rd2txt "c:/Users...-package.Rd"
> > 
> I have the same problem as David.
> I am using the latest version Vince Goulet's distribution on Windows
> (GNU Emacs 23.3; ESS 5.14). (I also had the same result with XEmacs.)
> 
> 2) When I use the shell R CMD... I get the expected output.
> 
> 1) When in the .Rd buffer I request the buffer-file-name I get:
> 
> buffer-file-name is a variable defined in `C source code'.
> Its value is "d:/xyz/man/Helpfile.Rd"
> Local in buffer Helpfile.Rd; global value is nil
> 
>   Automatically becomes buffer-local when set in any fashion.
>   This variable is potentially risky when used as a file local variable.
> 
> Documentation:
> Name of file visited in current buffer, or nil if not visiting a file.
> 
> This means I get the correct (working) filename in the buffer,
> but still an error when I try to preview the help file.
> 
  Any update on this?  I'm on Ubuntu 10.04 with ESS 5.14,
Gnu Emacs 23.1.1.
C-h v  buffer-file-name gives:
================
buffer-file-name is a variable defined in `C source code'.
Its value is nil
Local in buffer  *RoxygenPreview*; global value is nil
  Automatically becomes buffer-local when set in any fashion.
Documentation:
Name of file visited in current buffer, or nil if not visiting a file.
=================
The error is
Warning in file(con, "r") :
  cannot open file 'nil': No such file or directory
Error in file(con, "r") : cannot open the connection
Execution halted
  which makes it look like buffer-file-name is not getting set.
 However, I will also point out (if anyone's busy making
improvements) that it would be really great to have a single
command to preview text in a new buffer, rather than having
to C-c C-e C-r and then C-c C-p ...
  cheers
    Ben Bolker
    
    
More information about the ESS-help
mailing list