R/wpd_get_args.R

Defines functions wpd_get_args

Documented in wpd_get_args

#' wpd_get_args
#'
#' @export
#'
wpd_get_args <- function(){

  # get commandline arguments
  args       <- commandArgs(trailingOnly=TRUE)

  # process
  args_split <- strsplit(args, "=")
  args_list  <- lapply(args_split, `[[`, 2)
  names(args_list) <- unlist(lapply(args_split, `[[`, 1))

  # return
  args_list
}
petermeissner/wikipediadumbs documentation built on Nov. 5, 2019, 12:19 a.m.