Learn R Programming

froggeR (version 0.6.0)

write_variables: Write Variables YAML for Quarto Projects

Description

This function creates a _variables.yml file in a Quarto project and opens it for editing.

Usage

write_variables(path = here::here())

Value

Invisibly returns the path to the created file.

Arguments

path

Character. Path to the project directory. Default is current project root via here.

Details

The function will attempt to use the current froggeR settings from the global config path. If no global configurations exist, a template _variables.yml will be created. This file stores reusable metadata (author name, email, ORCID, etc.) that can be referenced throughout Quarto documents.

See Also

settings, save_variables, brand_settings, quarto_project

Examples

Run this code
# Write the _variables.yml file
if (interactive()) {
  temp_dir <- tempdir()
  # In an interactive session, this would also open the file for editing.
  write_variables(temp_dir)
  # Verify the file was created
  file.exists(file.path(temp_dir, "_variables.yml"))
}

Run the code above in your browser using DataLab