RiKi, that is fortunately very easy to do on the Mac and Linux with the bang and Rscript:
#!/usr/bin/env Rscript --vanilla local({ r <- getOption("repos") r["CRAN"] <- "https://cloud.r-project.org/" options(repos = r) }) update.packages() I have no idea whether Rscript even exists on Windows and if so, how to call it. greetings, el On 19/01/2021 00:12, Richard Kimberly Heck wrote: [...] > Presumably one could script the R session itself so that the needed > object was exported? I.e., can one do that from the command line? > That's the kind of thing that an external template would do. [...] -- To email me replace 'nospam' with 'el' -- lyx-devel mailing list lyx-devel@lists.lyx.org http://lists.lyx.org/mailman/listinfo/lyx-devel