Validates and normalises arguments from the parsed argparse result, then
calls cli_nemo_tidy(). When wf is non-NULL it overrides args$workflow
(used by downstream packages that fix the workflow at the script level,
e.g. tidywigits.R).
Arguments
- args
Named list of parsed CLI arguments, as returned by argparse. Expected fields:
format,in_dir,output_dir,input_id(optional),output_id(optional),ulid,prefix_include,dbname,dbuser,include,exclude,workflow(may beNULLwhenwfis provided),quiet.output_idandulidare mutually exclusive at the CLI level (enforced by argparse). When called directly, if both are setulidtakes precedence andoutput_idis silently ignored.- wf
(
character(1)orNULL)
Workflow override. When non-NULL, replacesargs$workflow.- dbdrv
(
DBIDriverorNULL)
DBI driver object (e.g.RPostgres::Postgres()). Required whenargs$formatis"db"; ignored otherwise. Supplied by the caller so that nemo does not depend on any specific database backend.
Examples
path <- system.file("extdata/tool1", package = "nemo")
args <- list(
format = "tsv", in_dir = path, output_dir = tempfile(),
input_id = "run1", output_id = NULL, ulid = FALSE,
prefix_include = FALSE, workflow = NULL, dbname = NULL, dbuser = NULL,
include = NULL, exclude = NULL, quiet = FALSE
)
cli_tidy_parse_args(args, wf = "workflow1")
#> [2026-07-28T09:32:42UTC] nemo INFO: Tidying dir: /home/runner/miniconda3/envs/pkgdown_env/lib/R/library/nemo/extdata/tool1
#> [2026-07-28T09:32:43UTC] nemo INFO: Tidy results written to dir: /tmp/RtmpLFaYvY/file1152741dbd2c
