R/clean_url.R

Defines functions clean_url

Documented in clean_url

#' Clean and format URL
#'
#' @param url The URL to clean
#' @return A cleaned and formatted URL
#' @keywords internal
clean_url <- function(url) {
  url <- trimws(url)
  url <- gsub("\\s*\\([^\\)]+\\)\\s*$", "", url)
  return(url)
}

Try the Argentum package in your browser

Any scripts or data that you put into this service are public.

Argentum documentation built on April 4, 2025, 3:48 a.m.