\Header{Sys.getenv}{Get Environment Variables}
\keyword{environment}{Sys.getenv}
\keyword{utilities}{Sys.getenv}
\begin{Description}\relax
\code{Sys.getenv} obtains the values of the environment variables named by
\code{x}.\end{Description}
\begin{Usage}
\begin{verbatim}
Sys.getenv(x)
\end{verbatim}
\end{Usage}
\begin{Arguments}
\begin{ldescription}
\item[\code{x}] a character vector, or missing
\end{ldescription}
\end{Arguments}
\begin{Value}
A vector of the same length as \code{x}, with the variable names as
its \code{names} attribute.  Each element holds the value of the
environment variable named by the corresponding component of \code{x}
(or \code{""} if no environment variable with that name was found).

On most platforms \code{Sys.getenv()} will return a named vector giving
the values of all the environment variables.\end{Value}
\begin{Note}\relax
\code{getenv} is an alias for backwards compatibility.\end{Note}
\begin{SeeAlso}\relax
\code{\Link{Sys.putenv}},
\code{\Link{getwd}} for the working directory.\end{SeeAlso}
\begin{Examples}
\begin{ExampleCode}
Sys.getenv(c("R_HOME", "R_PAPERSIZE", "R_PRINTCMD", "HOST"))
\end{ExampleCode}
\end{Examples}

