Create a Quarto file based on defined template
Source:R/create_from_template.R
create_from_template.Rd
This function creates a Quarto file based on defined template
by copying the necessary template files
into the _extensions
directory and generating
a new Quarto Markdown (.qmd
) file.
Value
This function does not return a value. It performs file operations to set up the Quarto IOM story template in the current working directory.
Details
The function performs the following steps:
Checks if
file_name
is provided. If not, it will be index per default.Verifies what
template
is selected.Creates the
_extensions
directory if it does not exist.Creates a subdirectory within
_extensions
for the specified extension.Copies the extension files from the package's internal
extdata
directory to_extensions
.Checks if the extension files were successfully copied.
Creates a new Quarto Markdown file based on the template.
Opens the new file in the editor.