[Rd] Rscript --args -e <cmd> / R --vanilla --slave --args -e <cmd> opens an interactive R session

Henrik Bengtsson henrik.bengtsson at ucsf.edu
Tue Sep 22 19:48:49 CEST 2015


When using Rscript -e <cmd>, (mistakenly) putting --args in front of
-e causes an interactive R session to start that does not quit
automatically and that does not display a prompt. For example,

{hb}: Rscript --vanilla -e "0"
[1] 0

{hb}: Rscript --vanilla -e "0" --args
[1] 0

{hb}: Rscript --vanilla --args -e "0"
1
[1] 1
2
[1] 2
quit("no")

Further troubleshooting narrows this down to:

{hb}: R --vanilla --slave --args -e 0
1
[1] 1
quit('no')

having this problem.

/Henrik



More information about the R-devel mailing list