Learn R Programming

RSuite (version 0.37-253)

tmpl_start: Creates a new template with the specified name, in the specified path.

Description

Creates a new template with the specified name, in the specified path.

Usage

tmpl_start(name, path = getwd(), add_prj = TRUE, add_pkg = TRUE,
  base_tmpl = "builtin")

Arguments

name

name of the template being created. (type: character(1))

path

path to the directory where the template should be created. If NULL will use the folder with user template. (type: character(1), default: getwd())

add_prj

if TRUE include project template to the template directory

add_pkg

if TRUE include package template in the template directory

base_tmpl

name of the package and/or project template (or path to it) to use for template creation. (type: character(1); default: builtin).

Details

Project templates are required to include a PARAMETERS file whereas package templates are required to include a DESCRIPTION file

If there is no path argument provided. The function will create the template in working directory.

See Also

Other in templates management: tmpl_list_registered

Examples

Run this code
# NOT RUN {
tmpl_dir <- tempfile("templ_")
tmpl_start(basename(tmpl_dir), path = tempdir())

# }

Run the code above in your browser using DataLab