Render README #1441
This file contains hidden or 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 | |
| schedule: | |
| - cron: '0 1 * * *' | |
| name: Render README | |
| jobs: | |
| render: | |
| name: Render README | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v2 | |
| - uses: r-lib/actions/setup-r@v2 | |
| - uses: r-lib/actions/setup-pandoc@v2 | |
| - name: Install system dependencies | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y libcurl4-openssl-dev | |
| sudo apt-get install -y libfreetype6-dev libpng-dev libtiff5-dev libjpeg-dev | |
| sudo apt-get install -y libfontconfig1-dev libfreetype6-dev libfribidi-dev libharfbuzz-dev | |
| - name: Install packages | |
| run: | | |
| Rscript -e 'install.packages("rmarkdown")' | |
| Rscript -e 'install.packages("curl")' | |
| Rscript -e 'install.packages("knitr")' | |
| Rscript -e 'install.packages("kableExtra")' | |
| Rscript -e 'install.packages("formattable")' | |
| Rscript -e 'install.packages("systemfonts")' | |
| Rscript -e 'install.packages("textshaping")' | |
| Rscript -e 'install.packages("ragg")' | |
| Rscript -e 'install.packages("here")' | |
| Rscript -e 'install.packages("tidyverse")' | |
| Rscript -e 'install.packages("plotly")' | |
| Rscript -e 'install.packages("knitr")' | |
| Rscript -e 'install.packages("httr")' | |
| Rscript -e 'install.packages("readr")' | |
| Rscript -e 'install.packages("openssl")' | |
| Rscript -e 'install.packages("zoo")' | |
| - name: Render README | |
| env: | |
| TEST_SECRET: ${{ secrets.TEST_SECRET}} | |
| run: Rscript -e 'rmarkdown::render("README.Rmd", output_format = "md_document")' | |
| - name: Render tallene | |
| env: | |
| CLIENT_SECRET: ${{ secrets.CLIENT_SECRET}} | |
| run: Rscript -e 'rmarkdown::render("tallene.Rmd", output_format = "html_document")' | |
| - name: Render tilmeldingsanalyse | |
| env: | |
| CLIENT_SECRET: ${{ secrets.CLIENT_SECRET}} | |
| run: Rscript -e 'rmarkdown::render("tilmeldingsanalyse.Rmd", output_format = "html_document")' | |
| - name: Commit results | |
| run: | | |
| git config --local user.email "actions@github.com" | |
| git config --local user.name "GitHub Actions" | |
| git add -A . | |
| git commit -m 'Re-build README.Rmd' || echo "No changes to commit" | |
| git push origin || echo "No changes to commit" |