register: Register a configuration

Description Usage Arguments Examples

View source: R/register.R

Description

Register a configuration.

Usage

1
2
register(..., maybe = FALSE, warn = TRUE, quiet = FALSE,
  where = NULL)

Arguments

...

(character|list) named arguments. Character are interpreted as files. List objects are used as they are.

maybe

(logical) If TRUE then loading a config file can fail. A warning is raised.

warn

(logical) If FALSE convert all warnings into messages.

quiet

(logical) Suppress all warnings and messages.

where

(environment) The environment used to store the configs.

Examples

1
2
3
4
5
6
file <- tempfile(fileext = "R")
writeLines("x<-2\ny<-1", file)
cnf::register(config = list(x = 1))
cnf::getcnf("config")
cnf::register(config = file, warn = FALSE)
cnf::getcnf("config")

INWTlab/cnf documentation built on Sept. 27, 2021, 6:59 a.m.