download_sqlite_release: Download SQLite file from GitHub release

View source: R/github_release_utils.R

download_sqlite_releaseR Documentation

Download SQLite file from GitHub release

Description

Downloads a SQLite database file from the latest or a specific GitHub release.

Usage

download_sqlite_release(
  owner,
  repo,
  asset_name,
  dest_dir,
  tag = NULL,
  algo = "sha256",
  token = Sys.getenv("GITHUB_PAT"),
  overwrite = TRUE
)

Arguments

owner

Repository owner.

repo

Repository name.

asset_name

Name of the SQLite asset in the release.

dest_dir

Local directory where the file should be saved.

tag

Optional release tag (e.g., "v1.2.0"). If NULL, the latest release is used.

algo

Hash algorithm (default: "sha256").

token

Optional GitHub token. Defaults to Sys.getenv("GITHUB_PAT").

overwrite

Whether to overwrite existing file (default: TRUE).

Value

Invisibly returns the full path to the downloaded file.

Examples

## Not run: 
download_sqlite_release(
  owner = "myuser",
  repo = "myrepo",
  asset_name = "database.sqlite",
  dest_dir = tempdir()
)

## End(Not run)

acdcquery documentation built on Feb. 19, 2026, 5:07 p.m.