Skip to content

added dependencies #13

added dependencies

added dependencies #13

Workflow file for this run

on:
push:
branches: main
jobs:
build:

Check failure on line 7 in .github/workflows/bookdown.yaml

View workflow run for this annotation

GitHub Actions / .github/workflows/bookdown.yaml

Invalid workflow file

You have an error in your yaml syntax on line 7
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@v2
- name: Setup R
uses: r-lib/actions/setup-r@v2
- name: Install Homebrew and pandoc
run: |
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
echo "/home/linuxbrew/.linuxbrew/bin" >> $GITHUB_PATH
eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)"
brew install pandoc
- name: Install system dependencies
run: |
sudo apt-get update
sudo apt-get install -y libcurl4-openssl-dev libssl-dev libxml2-dev
- name: Cache Renv packages
uses: actions/cache@v4
with:
path: $HOME/.local/share/renv
key: r-${{ hashFiles('renv.lock') }}
restore-keys: r-
- name: Cache bookdown results
uses: actions/cache@v4
with:
path: _bookdown_files
key: bookdown-${{ hashFiles('**/*Rmd') }}
restore-keys: bookdown-
- name: Install packages
run: |
R -e 'install.packages("renv")'
R -e 'renv::restore()'
- name: Build site
run: Rscript -e 'bookdown::render_book()'
- name: Install npm
uses: actions/setup-node@v3
- name: Deploy to Netlify
# NETLIFY_AUTH_TOKEN added in the repo's secrets
env:
NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }}
NETLIFY_SITE_ID: ${{ secrets.NETLIFY_SITE_ID }}
run: |
npm install netlify-cli -g
netlify deploy --prod --dir _book