Skip to content

Update workflow and formatting #124

Update workflow and formatting

Update workflow and formatting #124

Workflow file for this run

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}