Re: [ESS] How to get working Rnw file name inside script

2024-05-08 Thread Susumu Tanimura via ESS-help
Hi Rrof. Goulet, Thank you very much for sharing the function. It works. Now I noticed that the return value of commandArgs() inside Rnw with ess includes a working Rnw file name. \begin{Schunk} \begin{Sinput} > commandArgs() \end{Sinput} \begin{Soutput} [1] "/usr/lib/R/bin/exec/R"

Re: [ESS] How to get working Rnw file name inside script

2024-05-08 Thread Vincent Goulet via ESS-help
I'm not sure this is what you're looking for, but here goes. I have been using the following function for a number of years to extract the name of the file from which Sweave is called. ### ### getSourceName() ### ## Extract the name of the file used in the command 'Sweave' calling ## this func