Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/inbo/checklist
An R package for checking R packages and R code
https://github.com/inbo/checklist
checklist continuous-integration continuous-testing quality-assurance r
Last synced: about 1 month ago
JSON representation
An R package for checking R packages and R code
- Host: GitHub
- URL: https://github.com/inbo/checklist
- Owner: inbo
- License: gpl-3.0
- Created: 2020-07-06T07:53:41.000Z (over 4 years ago)
- Default Branch: main
- Last Pushed: 2024-05-28T15:56:13.000Z (7 months ago)
- Last Synced: 2024-05-29T07:08:52.242Z (7 months ago)
- Topics: checklist, continuous-integration, continuous-testing, quality-assurance, r
- Language: R
- Homepage: https://inbo.github.io/checklist
- Size: 1.6 MB
- Stars: 10
- Watchers: 8
- Forks: 2
- Open Issues: 15
-
Metadata Files:
- Readme: README.Rmd
- Contributing: .github/CONTRIBUTING.md
- License: LICENSE.md
- Code of conduct: .github/CODE_OF_CONDUCT.md
- Citation: CITATION.cff
Awesome Lists containing this project
- jimsghstars - inbo/checklist - An R package for checking R packages and R code (R)
README
---
output: github_document
---[![Project Status: Active – The project has reached a stable, usable state and is being actively developed.](https://www.repostatus.org/badges/latest/active.svg)](https://www.repostatus.org/#active)
[![Lifecycle:maturing](https://img.shields.io/badge/lifecycle-maturing-blue.svg)](https://lifecycle.r-lib.org/articles/stages.html#maturing-1)
![GitHub](https://img.shields.io/github/license/inbo/checklist)
[![License](https://img.shields.io/badge/license-GPL--3-blue.svg?style=flat)](https://www.gnu.org/licenses/gpl-3.0.html)
[![Release](https://img.shields.io/github/release/inbo/checklist.svg)](https://github.com/inbo/checklist/releases)
[![R build status](https://github.com/inbo/checklist/workflows/check%20package%20on%20main/badge.svg)](https://github.com/inbo/checklist/actions)
![r-universe name](https://inbo.r-universe.dev/badges/:name?color=c04384)
![r-universe package](https://inbo.r-universe.dev/badges/checklist)
[![Codecov test coverage](https://codecov.io/gh/inbo/checklist/branch/main/graph/badge.svg)](https://app.codecov.io/gh/inbo/checklist?branch=main)
![GitHub code size in bytes](https://img.shields.io/github/languages/code-size/inbo/checklist.svg)
![GitHub repo size](https://img.shields.io/github/repo-size/inbo/checklist.svg)
[![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.4028303.svg)](https://doi.org/10.5281/zenodo.4028303)
# The Checklist Package
```{r setup, include = FALSE}
knitr::opts_chunk$set(
collapse = TRUE, comment = "#>", fig.path = "man/figures/README-",
out.width = "100%", eval = FALSE
)
```The goal of `checklist` is to provide an elaborate and strict set of checks for R packages and R code.
## Installation
You can install the package from the [INBO universe](https://inbo.r-universe.dev/builds) via
```{r universe}
# Enable the INBO universe
options(
repos = c(
inbo = "https://inbo.r-universe.dev", CRAN = "https://cloud.r-project.org"
)
)
# Install the packages
install.packages("checklist")
```If that doesn't work, you can install the version from [GitHub](https://github.com/inbo/checklist/) with:
```{r installation}
# install.packages("remotes")
remotes::install_github("inbo/checklist")
```## Setting a default organisation
We created `checklist` with the Research Institute for Nature and Forest (INBO) in mind.
When you don't specify the organisation, `checklist` assumes the code was written by INBO personnel.
INBO has specific requirements which are not relevant for external users of `checklist`.When you are not writing code for INBO, we recommend that you set a default `organisation`.
Below we specify the defaults for INBO.
More details in `vignette("organisation", package = "checklist")`.```{r organisation}
library(checklist)
org <- organisation$new(
github = "inbo", community = "inbo", email = "[email protected]",
rightsholder = "Research Institute for Nature and Forest (INBO)",
funder = "Research Institute for Nature and Forest (INBO)",
organisation = list(
"inbo.be" = list(
affiliation = c(
en = "Research Institute for Nature and Forest (INBO)",
nl = "Instituut voor Natuur en Bosonderzoek (INBO)"
),
orcid = TRUE
)
)
)
default_organisation(org = org)
```## Using `checklist` on a package.
Before you can run the checks, you must initialise `checklist` on the package.
Either use `create_package()` to create a new package from scratch.
Or use `setup_package()` on an existing package.
More details in `vignette("getting_started", package = "checklist")`.```{r package-initialise}
create_package()
```Once initialised, you can run all the checks with `check_package()`.
Or run the individual checks.```{r package-checks}
check_cran()
check_description()
check_documentation()
check_lintr()
check_filename()
check_folder()
update_citation()
```To allow some of the warnings or notes, first run the checks and store them in an object.
Update `checklist.yml` by writing that object.```{r package-allow-warnings}
x <- check_package()
write_checklist(x)
```## Using `checklist` on a project.
Before you can run the checks, you must initialise `checklist` on the project.
Either use `create_project()` to create a new package from scratch.
Or use `setup_project()` on an existing package.
More details in `vignette("getting_started_project", package = "checklist")`.```{r project-initialise}
library(checklist)
create_project()
```Once initialised, you can run all the checks with `check_project()`.
Or run the individual checks.```{r project-checks}
check_lintr()
check_filename()
check_folder()
update_citation()
```To allow some of the warnings or notes, first run the checks and store them in an object.
Update `checklist.yml` by writing that object.```{r project-allow-warnings}
x <- check_project()
write_checklist(x)
```