-
Notifications
You must be signed in to change notification settings - Fork 32
54 lines (46 loc) · 1.41 KB
/
vignette.yml
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
53
54
on:
push:
branches:
- "master"
pull_request:
branches:
- "*"
name: vignette
jobs:
vignette:
defaults:
run:
shell: bash -l {0}
strategy:
matrix:
config:
- { os: macos-latest }
runs-on: ${{ matrix.config.os }}
env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
steps:
- uses: actions/checkout@v4
- uses: r-lib/actions/setup-r@v2
id: install-r
with:
use-public-rspm: true
- uses: r-lib/actions/setup-pandoc@v2
- name: Cache R packages
uses: actions/cache@v4
with:
path: /home/runner/work/_temp/Library
key: ${{ runner.OS }}-R-${{ steps.install-r.outputs.installed-r-version }}-cache-${{ hashFiles('.github/depends.Rds') }}
restore-keys: |
${{ runner.OS }}-R-${{ steps.install-r.outputs.installed-r-version }}-cache-
- uses: r-lib/actions/setup-r-dependencies@v2
with:
extra-packages: pkgdown
- name: Install package
run: R CMD INSTALL .
- name: Build and deploy pkgdown site
if: github.actor == 'zktuong' && github.repository == 'zktuong/ktplots'
run: |
git config --local user.name "$GITHUB_ACTOR"
git config --local user.email "[email protected]"
Rscript -e 'pkgdown::deploy_to_branch(new_process = FALSE)'
shell: bash -l {0}