#' @title Get the Remotes from a Package
#' @description Parse a DESCRIPTION file and returns the remotes
#'
#' @param path Path to DESCRIPTION file
#'
#' @return Character vector of remotes
#' @export
#' @examples
#' path = example_description_file()
#' get_remotes(path)
get_remotes = function(path = "DESCRIPTION"){
if (is.character(path)) {
path = read_dcf(path)
path = path$dcf
}
remotes = path$Remotes[[1]]
remotes = trimws(remotes)
remotes = split_remotes(remotes)
if (is.null(remotes)) {
remotes = ""
}
return(remotes)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.