Skip to content

Nightly Knit README.Rmd #15

Nightly Knit README.Rmd

Nightly Knit README.Rmd #15

on:
schedule:
- cron: '0 0 * * *'
workflow_dispatch:
name: Nightly Knit README.Rmd
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: r-lib/actions/setup-pandoc@v2
- uses: r-lib/actions/setup-r@v2
- uses: r-lib/actions/setup-r-dependencies@v2
- name: Install README.Rmd dependencies
run: |
Rscript -e 'install.packages(c("pak", "rmarkdown", "knitr"))'
- name: Install the local package
run: |
Rscript -e 'pak::local_install(".")'
- name: Render README.Rmd file and Commit Results
run: |
Rscript -e 'rmarkdown::render("README.Rmd")'
git config --local user.name "$GITHUB_ACTOR"
git config --local user.email "[email protected]"
git commit README.* -m 'Re-build Rmarkdown files' || echo "No changes to commit"
git push origin || echo "No changes to commit"