R/util-construct_Renviron_path.R

Defines functions construct_Renviron_path

Documented in construct_Renviron_path

#' Construct Path of User's .Renviron File
#'
#' @return A character vector representing the path to the user's `.Renviron`
#'   file.
#' @keywords internal
construct_Renviron_path <- function() {
  path <- Sys.getenv("HOME")
  if (nzchar(path)) {
    path <- normalizePath("~/")
  }
  file.path(path, ".Renviron")
}
TIBHannover/BacDiveR documentation built on June 2, 2022, 2:51 p.m.