Skip to content

Fix errors and warnings in GHA workflows #34

Fix errors and warnings in GHA workflows

Fix errors and warnings in GHA workflows #34

Workflow file for this run

on:
push:
branches:
- main
paths:
- DESCRIPTION
- .github/workflows/codemeta.yml
name: Render codemeta
jobs:
render:
name: Render codemeta
runs-on: macOS-latest
if: "!contains(github.event.head_commit.message, 'cm-skip')"
env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
steps:
- uses: actions/checkout@v4
- uses: r-lib/actions/setup-r@v2
- name: Install remotes
run: Rscript -e 'install.packages("remotes")'
- name: Install codemetar (dev version)
run: Rscript -e 'remotes::install_github("ropensci/codemetar")'
- name: Render codemeta
run: Rscript -e 'codemetar::write_codemeta()'
- name: Commit results
run: |
git commit codemeta.json -m 'Re-build codemeta.json' || echo "No changes to commit"
git push https://${{github.actor}}:${{secrets.GITHUB_TOKEN}}@github.com/${{github.repository}}.git HEAD:${{ github.ref }} || echo "No changes to commit"