Validates inputs, builds an argument vector, resolves runtime engine
(native, docker, apptainer), executes via processx::run(), checks
outputs, and returns a structured result.
Usage
ni_run(
call,
...,
dry_run = FALSE,
echo = interactive(),
provenance = TRUE,
error_on_status = TRUE,
return = c("result", "files")
)Arguments
- call
An
ni_callobject, or a spec ID (in which case remaining args are passed toni_call()).- ...
If
callis a spec ID, passed toni_call().- dry_run
Logical; if
TRUE, print the resolved command and return without executing.- echo
Logical; if
TRUE, print stdout/stderr in real time. Defaults tointeractive().- provenance
Logical; write a provenance JSON sidecar. Default
TRUE.- error_on_status
Logical; if
TRUE(default), error when the command exits with a non-zero status. IfFALSE, issue a warning instead.- return
One of
"result"(default) or"files".