Skip to content

update-datasets

update-datasets #97

name: update-datasets
on:
schedule:
- cron: '0 14 * * 1' # 2pm UTC Mondays
workflow_dispatch:
# Check out and build package, run data-raw/internal.R,
jobs:
update-datasets:
runs-on: ubuntu-latest
env:
GITHUB_PAT: ${{ secrets.GH_PAT }}
steps:
- uses: actions/checkout@v3
with:
ref: main
token: ${{ env.GITHUB_PAT }}
- uses: r-lib/actions/setup-r@v2
with:
r-version: release
use-public-rspm: true
- uses: r-lib/actions/setup-r-dependencies@v2
with:
extra-packages: any::gert, any::fs, any::here
- name: Update data
run: Rscript data-raw/just-new.R
- name: 🚀 Commit
run: |
git config user.name "github-actions"
git config user.email "[email protected]"
git add --all
git commit -m "🤖 Auto-update internal data"
git push