Update publications #17
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
on: | |
workflow_dispatch: | |
push: | |
branches: main | |
name: Quarto Publish EN | |
jobs: | |
build-deploy: | |
runs-on: ubuntu-latest | |
permissions: | |
contents: write | |
steps: | |
- name: Check out repository | |
uses: actions/checkout@v2 | |
- name: Set up Quarto | |
uses: quarto-dev/quarto-actions/setup@v2 | |
with: | |
version: pre-release | |
# install libcurl, needed for curl R package | |
# libfribidi-dev libharfbuzz-dev for textshaping | |
- name: Install cURL Headers | |
run: | | |
sudo apt-get install libcurl4-openssl-dev libfribidi-dev libharfbuzz-dev | |
- name: Install R | |
uses: r-lib/actions/setup-r@v2 | |
with: | |
r-version: '4.2.0' | |
- name: Install R Dependencies | |
uses: r-lib/actions/setup-renv@v2 | |
with: | |
cache-version: 1 | |
- name: Render book | |
run: Rscript -e 'babelquarto::render_website()' | |
- name: git config | |
run: | | |
git config --global user.email "[email protected]" | |
git config --global user.name "gh-pages committer" | |
- name: Commit results | |
run: | | |
cd _site | |
git init | |
git add . | |
git commit -m 'update website' | |
git push https://${{github.actor}}:${{secrets.GITHUB_TOKEN}}@github.com/${{github.repository}}.git HEAD:gh-pages --force |