r-ci
Easy and portable CI for R packages
This repository provides a script run.sh
for portable, flexible and lightweight Continuous Integration (CI) use at
GitHub Actions, Travis, Azure Pipelines and Docker for local testing and use -- all shown below via real examples -- and likely others such as GitLab.
This script contains the following key functions which are typically all a user needs to call:
./run.sh bootstrap
Sets up the R environment, installs auxiliary packages such as
testthat
ortinytest
../run.sh install_deps
Parses
DESCRIPTION
and installs the required packages.install_all
is a (slightly heavier) alternative pulling not only dependencies but also suggested packages../run.sh run_tests
Builds the package tarball, and runs tests on it resulting in the overall CI test pass or fail.