Skip to content

Bump r-lib/actions from 1 to 2 #93

Bump r-lib/actions from 1 to 2

Bump r-lib/actions from 1 to 2 #93

name: Build and Deploy RMarkdown Website
on:
workflow_dispatch:
push:
branches: main
pull_request:
branches: main
permissions:
contents: write
jobs:
build-and-deploy:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
- uses: r-lib/actions/setup-pandoc@v2
- uses: r-lib/actions/setup-r@v2
with:
install-r: false
use-public-rspm: true
- name: Install R system requirements
run: |
sudo apt-get update
sudo apt-get install libcurl4-openssl-dev libnetcdf-dev
- name: Install R dependencies
env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
run: |
install.packages(c("remotes", "rmarkdown", "rbi", "rbi.helpers", "pomp"))
remotes::install_github("sbfnk/fitR", dependencies = TRUE)
shell: Rscript {0}
- name: Render Site
run: Rscript -e "rmarkdown::render_site(input = 'Rmd', encoding = 'UTF-8')"
- name: Deploy 🚀
id: deployment
uses: JamesIves/github-pages-deploy-action@v4
with:
folder: Rmd/_site
clean: false