Skip to content

Regenerated docs

Regenerated docs #36

Workflow file for this run

# Name of the workflow
name: render-readme
# Controls when the action will run. Triggers include:
#
# - button trigger from github action page
# - on changes to readme.Rmd
on:
workflow_dispatch:
push:
paths:
- 'README.Rmd'
- '.github/workflows/render_readme.yml'
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
concurrency:

Check failure on line 20 in .github/workflows/render_readme.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/render_readme.yml

Invalid workflow file

You have an error in your yaml syntax on line 20
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
render-readme:
runs-on: macos-latest
env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
steps:
- name: Checkout repos
uses: actions/checkout@v3
- name: Setup R
uses: r-lib/actions/setup-r@v2
with:
use-public-rspm: true
- name: Setup pandoc
uses: r-lib/actions/setup-pandoc@v2
- name: Install dependencies
uses: r-lib/actions/setup-r-dependencies@v2
with:
extra-packages: any::rmarkdown, local::.
- name: Compile the readme
run: |
writeLines(
knitr::knit_expand(
"README.Rmd",
packagename = read.dcf("DESCRIPTION", "Package"),
gh_repo = Sys.getenv("GITHUB_REPOSITORY")
),
"README.Rmd"
)
rmarkdown::render("README.Rmd", output_file = "README.md", output_dir = ".")
shell: Rscript {0}
- name: Commit files
run: |
git config --local user.email "[email protected]"
git config --local user.name "GitHub Action"
git add README.md
# Also add README figures if they exist
if [ -d man/figures ]
then
git add man/figures/
fi
git diff-index --quiet HEAD || git commit -m "Automatic readme update"
git push origin || echo "No changes to push"