gh_releases: List releases from GitHub repository

gh_releasesR Documentation

List releases from GitHub repository

Description

Uses gh::gh() to fetch all available releases of the specified GitHub repository via GitHub's REST API and returns them as a tibble containing the columns id, version_nr, is_pre_release and is_draft.

Usage

gh_releases(
  owner,
  name,
  n = Inf,
  incl_pre_releases = FALSE,
  incl_drafts = FALSE
)

Arguments

owner

GitHub repository owner (GitHub user or organisation). A character scalar.

name

Repository name. A character scalar.

n

Number of releases to return. A positive integer or Inf. If Inf, all releases are returned, otherwise only the most recent n releases. Note that requesting many releases may result in multiple GitHub API calls, which can take a considerable amount of time.

incl_pre_releases

Whether or not to include pre-releases in the result. Pre-releases are usually not deemed ready for production and may be unstable. For more information, see the GitHub Docs.

incl_drafts

Whether or not to include draft releases in the result. For more information, see the GitHub Docs.

Value

A tibble with the columns id, version_nr, is_pre_release, and is_draft.

See Also

Other GitHub functions: gh_dir_ls(), gh_release_latest(), gh_text_file(), gh_text_files()

Examples

yay::gh_releases(owner = "jgm",
                 name = "pandoc",
                 n = 3L)

salim-b/yay documentation built on May 17, 2024, 5:24 a.m.