[ESS] tcsh, bash, and the inferior R process

Kasper Daniel Hansen khansen at stat.Berkeley.EDU
Mon Oct 15 19:43:50 CEST 2007


I have no idea why you observe a difference, but here is waht I see  
using bash:

Btw. how do you start Emacs - in a terminal or what?

On Oct 15, 2007, at 10:34 AM, Erik Iverson wrote:

> Hello -
>
> I have been using the "tcsh" shell under Linux for a while now.   
> Today,
> I experimented with changing my default shell to bash.  The  
> behavior of
> the inferior R process mode (iESS) in ESS seems to change depending on
> which shell I'm using, and I can't figure out why.
>
> First, my software.  I'm using ESS 5.3.6, R 2.5.1, XEmacs 21.5.24
> (Beta), all on RHEL4.  I've verified the issue using Emacs also, so
> XEmacs doesn't seem to be the problem.
>
> I am using ypchsh to change my default shell, since we use NIS here.
>
> So here is my problem.  I start an inferior R process using M-x R, and
> issue a command, say
>
>> 2 + 2
> [1] 4
>
> Now, if my shell is tcsh, I am able to move point to the line  
> containing
> "2 + 2", and hit "Return" to copy "2 + 2" to the inferior R mode's
> prompt.  I could then edit the command, and hit "Return" again to  
> submit
> it.
>
> However, after changing my default shell to the bash shell, moving  
> point
> to the "2 + 2" line and hitting "Return" copies the "2 + 2" command
> *and* submits it to the R process, so I see
>
>> 2 + 2
> [1] 4
>
> again, with only hitting "Return".  So I seem to have lost my editing
> capabilities.

I see this behavior as well. I find it strange that hitting RETURN  
should copy the line to the prompt line, but perhaps I just haven't  
been exposed to it.



> Another issue is that, using tcsh, I am used to hitting C-c C-c to  
> move
> point to a command prompt in the iESS buffer.
>
> Under bash, C-c C-c seems to do this properly, but it copies whatever
> line I'm on before doing it.  For example,
> hitting C-c C-c on the 2 + 2 line, I get
>
>> 2 + 2 C-c C-c
>>
>
> So it literally prints 'C-c C-c' in the iESS buffer.  Further, if I  
> hit
> C-c C-c on the
> [1] 4
> line, the minibuffer says "No command on this line." and point remains
> on that line.

I do _not_ see this. C-c C-c just brings me to the prompt no matter  
what.

Kasper

> If anyone has any idea why changing shells might do this, I'd be  
> glad to
> try some things!
>
> I do very often submit R code from a source file to the R process, and
> that still works just fine.  I do prefer that approach, but once in
> awhile find myself typing something quick in the iESS buffer.  I'm  
> just
> curious why the shell might be affecting the bahavior of that buffer.
> Hopefully this isn't something obvious that I've overlooked.  I've  
> only
> tried tcsh and bash, I suppose I could try some more shells and see  
> what
> behavior I observe.
>
> Thanks,
> Erik Iverson
> iverson at biostat.wisc.edu
>
> ______________________________________________
> 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