add basic info about qmd template (#231) #21
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: | |
push: | |
branches: | |
main | |
name: Render-Book-from-main | |
jobs: | |
quarto: | |
name: Render-Book | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: quarto-dev/quarto-actions/setup@v2 | |
- uses: r-lib/actions/setup-r@v2 | |
- uses: r-lib/actions/setup-pandoc@v2 | |
- uses: r-lib/actions/setup-r-dependencies@v2 | |
with: | |
extra-packages: local::. | |
- name: Render book | |
run: Rscript -e 'quarto::quarto_render()' | |
- name: Commit results | |
if: github.repository == 'ropensci-org/blog-guidance' | |
run: | | |
cp ghpagescname _book/CNAME | |
cp -r favicon/ _book/ | |
cp images/logo.png _book/logo.png | |
cd _book | |
git config --global user.email "[email protected]" | |
git config --global user.name "gh-pages committer" | |
git init | |
git add . | |
git commit -m 'update book' | |
git push https://${{github.actor}}:${{secrets.GITHUB_TOKEN}}@github.com/${{github.repository}}.git HEAD:gh-pages --force |