Skip to content

Commit b2c000e

Browse files
committed
ci(desrapbook): add temporary minimal versions of CI/CD from des-rap-book
1 parent c05138d commit b2c000e

File tree

2 files changed

+68
-0
lines changed

2 files changed

+68
-0
lines changed

.github/workflows/temp-lint.yaml

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
# Workflow adapted from https://github.com/r-lib/actions/tree/v2/examples
2+
3+
on:
4+
push:
5+
workflow_dispatch:
6+
7+
name: lint
8+
9+
permissions: read-all
10+
11+
jobs:
12+
lint:
13+
runs-on: ubuntu-latest
14+
env:
15+
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
16+
steps:
17+
- uses: actions/checkout@v4
18+
19+
- uses: r-lib/actions/setup-r@v2
20+
with:
21+
use-public-rspm: true
22+
23+
- uses: r-lib/actions/setup-r-dependencies@v2
24+
with:
25+
extra-packages: any::lintr, any::cyclocomp, local::.
26+
needs: lint
27+
28+
- name: Lint package
29+
run: lintr::lint_package()
30+
shell: Rscript {0}
31+
env:
32+
LINTR_ERROR_ON_LINT: true
33+
34+
- name: Lint rmarkdown
35+
run: lintr::lint_dir("rmarkdown")
36+
shell: Rscript {0}
37+
env:
38+
LINTR_ERROR_ON_LINT: true

.github/workflows/temp-test.yaml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: R-CMD-check.yaml
2+
3+
on:
4+
push:
5+
workflow_dispatch:
6+
7+
permissions: read-all
8+
9+
jobs:
10+
R-CMD-check:
11+
runs-on: ubuntu-latest
12+
env:
13+
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
14+
R_KEEP_PKG_SOURCE: yes
15+
steps:
16+
- uses: actions/checkout@v4
17+
18+
- uses: r-lib/actions/setup-pandoc@v2
19+
20+
- uses: r-lib/actions/setup-r@v2
21+
with:
22+
r-version: 'release'
23+
use-public-rspm: true
24+
25+
- uses: r-lib/actions/setup-r-dependencies@v2
26+
with:
27+
extra-packages: any::rcmdcheck
28+
needs: check
29+
30+
- uses: r-lib/actions/check-r-package@v2

0 commit comments

Comments
 (0)