Skip to content

Commit

Permalink
Rename parameter to try_bioconductor in p_install
Browse files Browse the repository at this point in the history
Was skip_bioc
  • Loading branch information
gadenbuie committed Sep 5, 2018
1 parent 0fd0417 commit c6fa8b1
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions R/p_install.R
Original file line number Diff line number Diff line change
Expand Up @@ -12,17 +12,15 @@
#' @param path The path to the directory that contains the package. It is
#' convenient to set \code{download_path} in .Rprofile options to the downloads
#' directory.
#' @param skip_bioc Should Bioconductor be skipped? Set to \code{FALSE} to
#' search for the package on Bioconductor (and install \code{\link{BiocManager}}
#' if not installed). By default, Bioconductor is skipped if
#' \code{\link{BiocManager}} is not installed.
#' @param try_bioconductor If \code{TRUE}, tries to install the package from
#' Bioconductor if it is not found on CRAN using \code{\link{BiocManager}}.
#' @keywords install package
#' @seealso \code{\link[utils]{install.packages}}
#' @export
#' @examples
#' \dontrun{p_install(pacman)}
p_install <- function(package, character.only = FALSE, force = TRUE,
skip_bioc = NULL,
try_bioconductor = TRUE,
path = getOption("download_path"), ...){

if(!character.only){
Expand Down Expand Up @@ -84,7 +82,7 @@ p_install <- function(package, character.only = FALSE, force = TRUE,

## if the CRAN install failed from not available warning try installing
## from bioconductor
if (isTRUE(bioconductor_env[['try_bioc_p']])) {
if (try_bioconductor && isTRUE(bioconductor_env[['try_bioc_p']])) {
try_bioc(package)
}
}
Expand Down

0 comments on commit c6fa8b1

Please sign in to comment.