-
Notifications
You must be signed in to change notification settings - Fork 131
/
Copy pathgolem_opts.Rd
113 lines (92 loc) · 2.98 KB
/
golem_opts.Rd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/golem-yaml-get.R, R/golem-yaml-set.R,
% R/set_golem_options.R
\name{get_golem_wd}
\alias{get_golem_wd}
\alias{get_golem_name}
\alias{get_golem_version}
\alias{set_golem_wd}
\alias{set_golem_name}
\alias{set_golem_version}
\alias{set_golem_options}
\title{\code{{golem}} options}
\usage{
get_golem_wd(use_parent = TRUE, pkg = golem::pkg_path())
get_golem_name(
config = Sys.getenv("GOLEM_CONFIG_ACTIVE", Sys.getenv("R_CONFIG_ACTIVE", "default")),
use_parent = TRUE,
pkg = golem::pkg_path()
)
get_golem_version(
config = Sys.getenv("GOLEM_CONFIG_ACTIVE", Sys.getenv("R_CONFIG_ACTIVE", "default")),
use_parent = TRUE,
pkg = golem::pkg_path()
)
set_golem_wd(
golem_wd = golem::pkg_path(),
pkg = golem::pkg_path(),
talkative = TRUE
)
set_golem_name(
name = golem::pkg_name(),
pkg = golem::pkg_path(),
talkative = TRUE,
old_name = golem::pkg_name()
)
set_golem_version(
version = golem::pkg_version(),
pkg = golem::pkg_path(),
talkative = TRUE
)
set_golem_options(
golem_name = golem::pkg_name(),
golem_version = golem::pkg_version(),
golem_wd = golem::pkg_path(),
app_prod = FALSE,
talkative = TRUE,
config_file = golem::get_current_config(golem_wd)
)
}
\arguments{
\item{use_parent}{\code{TRUE} to scan parent directories for
configuration files if the specified config file isn't found.}
\item{pkg}{The path to set the golem working directory.
Note that it will be passed to \code{normalizePath}.}
\item{config}{Name of configuration to read from. Defaults to
the value of the \code{R_CONFIG_ACTIVE} environment variable
("default" if the variable does not exist).}
\item{golem_wd}{Working directory of the current golem package.}
\item{talkative}{Should the messages be printed to the console?}
\item{name}{The name of the app}
\item{old_name}{The old name of the app, used when changing the name}
\item{version}{The version of the app}
\item{golem_name}{Name of the current golem.}
\item{golem_version}{Version of the current golem.}
\item{app_prod}{Is the \code{{golem}} in prod mode?}
\item{config_file}{path to the \code{{golem}} config file}
}
\value{
Used for side-effects for the setters, and values from the
config in the getters.
}
\description{
Set and get a series of options to be used with \code{{golem}}.
These options are found inside the \code{golem-config.yml} file, found in most cases
inside the \code{inst} folder.
}
\section{Set Functions}{
\itemize{
\item \code{set_golem_options()} sets all the options, with the defaults from the functions below.
\item \code{set_golem_wd()} defaults to \code{golem::golem_wd()}, which is the package root when starting a golem.
\item \code{set_golem_name()} defaults \code{golem::pkg_name()}
\item \code{set_golem_version()} defaults \code{golem::pkg_version()}
}
}
\section{Get Functions}{
Reads the information from \code{golem-config.yml}
\itemize{
\item \code{get_golem_wd()}
\item \code{get_golem_name()}
\item \code{get_golem_version()}
}
}