use_pkg: Depend on another package

use_pkgR Documentation

Depend on another package

Description

Wrapper around usethis::use_package() with different defaults and optional DESCRIPTION file tidying.

Usage

use_pkg(package, type = "Imports", min_version = TRUE, tidy = TRUE)

Arguments

package

Name of package to depend on.

type

Type of dependency: must be one of "Imports", "Depends", "Suggests", "Enhances", or "LinkingTo" (or unique abbreviation). Matching is case insensitive.

min_version

Optionally, supply a minimum version for the package. Set to TRUE to use the currently installed version or use a version string suitable for numeric_version(), such as "2.5.0".

tidy

Whether or not to run usethis::use_tidy_description() after adding package to dependencies.

Value

NULL, invisibly.

See Also

Other R package functions: is_pkg_cran(), is_pkg_dir(), is_pkg_installed(), is_pkgdown_dir(), ls_pkg()


salim-b/pal documentation built on Feb. 28, 2025, 6:51 p.m.