Skip to content

Commit 322b760

Browse files
committed
add default, comment
1 parent 294ce99 commit 322b760

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

R/pkg/R/utils.R

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -759,9 +759,14 @@ varargsToJProperties <- function(...) {
759759
launchScript <- function(script, combinedArgs, wait = FALSE) {
760760
if (.Platform$OS.type == "windows") {
761761
scriptWithArgs <- paste(script, combinedArgs, sep = " ")
762+
# on Windows, intern = F seems to mean output to the console. (documentation on this is missing)
762763
shell(scriptWithArgs, translate = TRUE, wait = wait, intern = wait) # nolint
763764
} else {
764-
system2(script, combinedArgs, wait = wait)
765+
# http://stat.ethz.ch/R-manual/R-devel/library/base/html/system2.html
766+
# stdout = F means discard output
767+
# stdout = "" means to its console (default)
768+
# Note that the console of this child process might not be the same as the running R process.
769+
system2(script, combinedArgs, stdout = "", wait = wait)
765770
}
766771
}
767772

0 commit comments

Comments
 (0)