Skip to content

Commit c6fa3b4

Browse files
committed
docs: rework example in run_bin
1 parent d6e17ec commit c6fa3b4

File tree

2 files changed

+12
-3
lines changed

2 files changed

+12
-3
lines changed

R/run_bin.R

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,11 @@
1313
#' \dontrun{
1414
#' # Example assumes that 'my-env' exists and contains 'python'
1515
#' # Run 'python' with a script in 'my-env' environment
16-
#' condathis::run_bin("python", "script.py", env_name = "my-env", verbose = "silent")
16+
#' condathis::run_bin(
17+
#' "python", "-c", "import sys; print(sys.version)",
18+
#' env_name = "my-env",
19+
#' verbose = "output"
20+
#' )
1721
#'
1822
#' # Run 'ls' command with additional arguments
1923
#' condathis::run_bin("ls", "-la", env_name = "my-env")
@@ -27,7 +31,8 @@ run_bin <- function(
2731
verbose = "silent",
2832
error = c("cancel", "continue"),
2933
stdout = "|",
30-
stderr = "|") {
34+
stderr = "|"
35+
) {
3136
error <- rlang::arg_match(error)
3237
if (isTRUE(identical(error, "cancel"))) {
3338
error_var <- TRUE

man/run_bin.Rd

Lines changed: 5 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)