uniset_autoUpS: Automatically update Settings

View source: R/gen_functions.R

uniset_autoUpSR Documentation

Automatically update Settings

Description

Use this function within your code to automatically update the settings from the users settings file

Usage

uniset_autoUpS(uniset_handover, setupFunc = NULL)

Arguments

uniset_handover

List length two, containing two elements:

  1. pkgname: The name of the target package.

  2. funcname: The name of the function in the target package handing over the required values. See examples at uniset.

setupFunc

Character length one. The name of the function in the target package performing the setup, i.e. the name of the function that is containing the uniset function uniset_setup. Defaults to 'NULL'; has to be changed.

Details

If 'autoUpdateSettings' in the local settings.R file is left at 'TRUE', the settings will be checked resp. updated automatically every time a function in the target package is calling uniset_autoUpS.

Value

Is primarily called for its side effects, i.e to automatically update / (re-)source the settings file. Returns (invisible) 'FALSE' if the the update was unsuccessful, otherwise an (invisible) list with the settings sourced from the settings.R file.

Important

This function is meant to be called from within the target package.

Note

Please refer to uniset for a link to examples and a real-world demo.

Examples

{
## Not run: 
# to be called from within the target package
uniset_autoUpS(uniset_handover, "dogPack_demo_setup")

## End(Not run)
}

uniset documentation built on March 28, 2022, 1:05 a.m.