Writes a YAML configuration file pre-filled with the standard toolero
folder structure and naming conventions. Edit the file to define a custom
project layout, then pass its path to init_project() via the config
argument.
Arguments
- filename
A character string. Name of the YAML file to create (e.g.,
"linguistics-project.yml"). Must be supplied explicitly.- path
A character string. Directory in which to write the file. Defaults to
"."(the current working directory). Consider using"~"(your home directory) so the file is easy to reference in futureinit_project()calls regardless of which project is active.- overwrite
Logical. If
TRUE, overwrites an existing file at the same location. Defaults toFALSE.
Details
The file uses the same schema as the _toolero.yml that init_project()
writes into a project, so a config you author by hand and a manifest a
project carries are the same kind of document. The only difference is who
wrote it.
Examples
if (FALSE) { # \dontrun{
# Write to the current working directory
generate_project_config("my-project.yml")
# Write to home directory for easy reuse across projects
generate_project_config("linguistics-project.yml", path = "~")
# Overwrite an existing config
generate_project_config("my-project.yml", overwrite = TRUE)
} # }
