R/update.R

Defines functions self_update refresh_warrior detach_warrior

Documented in detach_warrior refresh_warrior self_update

#' Self Update from Github
#' Self updates the package, acctually it reinstalls it.
#' @export
#'
#' @examples
#' self_update()
self_update <- function(){
  waRRior::print_if_verbose("Initiating self update", T)
  install_github("joelgsponer/warrior2")
  waRRior::print_if_verbose("Done", T)
}
# ---
#' Refresh
#'
#' @return
#' @export
#'
#' @examples
refresh_warrior <- function(){
  detach("package:waRRior", unload=TRUE)
  library(waRRior)
}
# ---
#' Detach
#'
#' @return
#' @export
#'
#' @examples
detach_warrior <- function(){
  detach("package:waRRior", unload=TRUE)
}
joelgsponer/waRRior2 documentation built on Feb. 22, 2020, 3:34 a.m.