From d42388f7e459ecb584cece6acf60dda674cd78d8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Calero=20Valdez?= Date: Sat, 11 Nov 2023 17:41:12 +0100 Subject: [PATCH] new R-CMD-Check --- .github/workflows/R-CMD-check.yaml | 57 ++++++++++++++++++++---------- README.Rmd | 4 +-- README.md | 4 +-- 3 files changed, 42 insertions(+), 23 deletions(-) diff --git a/.github/workflows/R-CMD-check.yaml b/.github/workflows/R-CMD-check.yaml index 145f0dd..a3ac618 100644 --- a/.github/workflows/R-CMD-check.yaml +++ b/.github/workflows/R-CMD-check.yaml @@ -1,30 +1,49 @@ -# For help debugging build failures open an issue on the RStudio community with the 'github-actions' tag. -# https://community.rstudio.com/new-topic?category=Package%20development&tags=github-actions +# Workflow derived from https://github.com/r-lib/actions/tree/v2/examples +# Need help debugging build failures? Start at https://github.com/r-lib/actions#where-to-find-help on: push: - branches: - - main - - master + branches: [main, master] pull_request: - branches: - - main - - master + branches: [main, master] name: R-CMD-check jobs: R-CMD-check: - runs-on: macOS-latest + runs-on: ${{ matrix.config.os }} + + name: ${{ matrix.config.os }} (${{ matrix.config.r }}) + + strategy: + fail-fast: false + matrix: + config: + - {os: macos-latest, r: 'release'} + - {os: windows-latest, r: 'release'} + - {os: ubuntu-latest, r: 'devel', http-user-agent: 'release'} + - {os: ubuntu-latest, r: 'release'} + - {os: ubuntu-latest, r: 'oldrel-1'} + env: GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} + R_KEEP_PKG_SOURCE: yes + steps: - - uses: actions/checkout@v2 - - uses: r-lib/actions/setup-r@v1 - - name: Install dependencies - run: | - install.packages(c("remotes", "rcmdcheck")) - remotes::install_deps(dependencies = TRUE) - shell: Rscript {0} - - name: Check - run: rcmdcheck::rcmdcheck(args = "--no-manual", error_on = "error") - shell: Rscript {0} + - uses: actions/checkout@v3 + + - uses: r-lib/actions/setup-pandoc@v2 + + - uses: r-lib/actions/setup-r@v2 + with: + r-version: ${{ matrix.config.r }} + http-user-agent: ${{ matrix.config.http-user-agent }} + use-public-rspm: true + + - uses: r-lib/actions/setup-r-dependencies@v2 + with: + extra-packages: any::rcmdcheck + needs: check + + - uses: r-lib/actions/check-r-package@v2 + with: + upload-snapshots: true diff --git a/README.Rmd b/README.Rmd index 9f61c6f..7dd6f56 100644 --- a/README.Rmd +++ b/README.Rmd @@ -15,10 +15,10 @@ knitr::opts_chunk$set( # seminrstudio - + [![CRAN status](https://www.r-pkg.org/badges/version/seminrstudio)](https://CRAN.R-project.org/package=seminrstudio) [![Codecov test coverage](https://codecov.io/gh/sem-in-r/seminrstudio/branch/master/graph/badge.svg)](https://codecov.io/gh/sem-in-r/seminrstudio?branch=master) +[![R-CMD-check](https://github.com/sem-in-r/seminrstudio/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/sem-in-r/seminrstudio/actions/workflows/R-CMD-check.yaml) The goal of seminrstudio is to to provide a UI based interface to the `seminr` package. diff --git a/README.md b/README.md index 18d7b1e..8133094 100644 --- a/README.md +++ b/README.md @@ -3,13 +3,13 @@ # seminrstudio - + [![CRAN status](https://www.r-pkg.org/badges/version/seminrstudio)](https://CRAN.R-project.org/package=seminrstudio) [![Codecov test coverage](https://codecov.io/gh/sem-in-r/seminrstudio/branch/master/graph/badge.svg)](https://codecov.io/gh/sem-in-r/seminrstudio?branch=master) +[![R-CMD-check](https://github.com/sem-in-r/seminrstudio/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/sem-in-r/seminrstudio/actions/workflows/R-CMD-check.yaml) The goal of seminrstudio is to to provide a UI based interface to the