parse_deps: Parse package dependency strings.

View source: R/package-deps.R

parse_depsR Documentation

Parse package dependency strings.

Description

Parse package dependency strings.

Usage

parse_deps(string)

Arguments

string

to parse. Should look like "R (>= 3.0), ggplot2" etc.

Value

list of two character vectors: name package names, and version package versions. If version is not specified, it will be stored as NA.

Examples

parse_deps("httr (< 2.1),\nRCurl (>= 3)")
# only package dependencies are returned
parse_deps("utils (== 2.12.1),\ntools,\nR (>= 2.10),\nmemoise")

pkgload documentation built on June 28, 2024, 5:07 p.m.