On Fri, 17 Dec 2021 18:48:29 +0100 Patrice Kiener <patrice.kie...@inmodelia.com> wrote:
> system2(getOption("editor"), fileREP, wait = FALSE) Starting a new terminal is somewhat hard, but the shortest path to getting this particular command working would be options(editor = 'gvim'). It's almost like Vim in a terminal, plus a few features useful in a windowed interface. Note that gvim backgrounds itself by default, so this would break edit() and file.edit(): since the GVim process started by R terminates almost immediately after spawning a child to do the rest of the work, R decides that the editing session is done. Unfortunately, it's hard to make R's edit() pass the -f flag to gvim to prevent it from doing that, but a trivial shell script wrapper could be used for that purpose: #!/bin/sh exec gvim -f "$@" -- Best regards, Ivan _______________________________________________ R-SIG-Debian mailing list R-SIG-Debian@r-project.org https://stat.ethz.ch/mailman/listinfo/r-sig-debian