print_cmd_args: Prints Command Line Args

Description Usage Arguments Examples

Description

Logs out all command line arguments at the INFO level.

Usage

1

Arguments

args

list of command line args, generated from argparse::parse_args

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
library(argparse)

start_logging()

description <- "TEST"
parser <- ArgumentParser(description = description)
parser$add_argument("--test_opt", help = "This is a test")
parser$add_argument("--log", default = NULL, help = "Name of log config file [$(default)]")
args <- parser$parse_args()

print_cmd_args(args)

jnguyen92/scriptR documentation built on May 8, 2019, 11:12 p.m.