Learn R Programming

xfun (version 0.21)

github_releases: Get the tags of Github releases of a repository

Description

Read the HTML source of the release page and parse the tags of the releases.

Usage

github_releases(repo, subpath = "", pattern = "(v[0-9.]+)")

Arguments

repo

The repository name of the form user/repo, e.g., "yihui/xfun".

subpath

A character string to be appended to the URL of Github releases (i.e., https://github.com/user/repo/releases/). For example, you may use subpath = "latest" to get the tag of the latest release.

pattern

A regular expression to extract the tags from the HTML source. It must contain a group (i.e., must have a pair of parentheses).

Value

A character vector of (GIT) tags.

Examples

Run this code
# NOT RUN {
if (interactive()) xfun::github_releases("yihui/xfun")
# }

Run the code above in your browser using DataLab