-
Notifications
You must be signed in to change notification settings - Fork 23
52 lines (45 loc) · 1.38 KB
/
r-check.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
# Workflow derived from https://github.com/r-lib/actions/tree/master/examples
# Need help debugging build failures? Start at https://github.com/r-lib/actions#where-to-find-help
on:
push:
branches: [main, master, release-1.5]
paths:
- '.github/**'
- 'lang/R/**'
pull_request:
branches: [main, master, release-1.5]
paths:
- '.github/**'
- 'lang/R/**'
name: R package
defaults:
run:
working-directory: lang/R
jobs:
R-CMD-check:
runs-on: ubuntu-latest
container:
image: rocker/verse:latest
steps:
- uses: actions/checkout@v2
- name: Install dependencies
run: |
install.packages(c("remotes", "testthat", "roxygen2", "devtools", "rcmdcheck"))
remotes::install_deps(dependencies=TRUE, upgrade="never")
tinytex::tlmgr_install("amsmath")
shell: Rscript {0}
- name: Document
run: |
devtools::document()
shell: Rscript {0}
- name: Check
env:
_R_CHECK_CRAN_INCOMING_: false
run: |
options(crayon.enabled=TRUE)
rcmdcheck::rcmdcheck(args = c("--no-manual", "--as-cran", "--run-donttest"), error_on="warning", check_dir="check")
shell: Rscript {0}
- name: Show testthat output
if: always()
run: find check -name 'testthat.Rout*' -exec cat '{}' \; || true
shell: bash