helper func to update 1 metadata attribute (e.g. "ejam_package_version") in all pkg datasets updates EJAM/data/*.rda (BUT NOT ARROW & NOT TXT FILES)
Source:R/utils_metadata_add.R
metadata_update_attr.Rdhelper func to update 1 metadata attribute (e.g. "ejam_package_version") in all pkg datasets updates EJAM/data/*.rda (BUT NOT ARROW & NOT TXT FILES)
Usage
metadata_update_attr(
x,
attr_name = "ejam_package_version",
newvalue = ejam_package_version_current(),
exclude_atomic_vectors = TRUE,
only_update_if_had_been_set = FALSE
)Arguments
- x
if missing, defaults to all items found in EJAM pkg; otherwise, a vector of 1+ quoted names of data object(s), like "testpoints_10"
- attr_name
e.g. "ejam_package_version"
- newvalue
the new value of that attribute
- exclude_atomic_vectors
if TRUE, avoids updating attributes on atomic vectors like names_e, since it is distracting when looking at one in console, like
names_e- only_update_if_had_been_set
set to TRUE to only update this attribute for data objects where that object already had a value set for this attribute, to update only but not create/add attribute.
See also
metadata_check_print() metadata_check() metadata_add() metadata_update_attr() metadata_add_and_use_this() dataset_documenter()