R/account.R

Defines functions using_account

Documented in using_account

#' @rdname account
#' @title Determine whether a given user account is being used
#'
#' @param username Username to check for
#'
#' @return A logical value
#' @export
#'
#' @examples
#' using_account("root")
using_account <- function(username) {
  assert_string(username)
  identical(Sys.info()[["effective_user"]], username)
}

Try the ami package in your browser

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

ami documentation built on April 4, 2025, 2:39 a.m.