Skip to content

archive

archive #152

Workflow file for this run

# For help debugging build failures open an issue on the RStudio community with the 'github-actions' tag.
# https://community.rstudio.com/new-topic?category=Package%20development&tags=github-actions
on:
# push:
# branches:
# - main
schedule:
- cron: "0 0 * * 0" # midnight on sunday
name: archive
jobs:
render:
name: archive
runs-on: macOS-latest
env:
GITHUB_PAT: ${{ secrets.GH_PAT }}
GH_KEY: ${{ secrets.GH_KEY }}
GH_SECRET: ${{ secrets.GH_SECRET }}
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY}}
steps:
- uses: actions/checkout@v2
- uses: r-lib/actions/setup-r@v2
- uses: r-lib/actions/setup-r-dependencies@v2
with:
packages: |
any::gh
any::aws.s3
any::purrr
any::curl
- name: Copy data
run: Rscript -e 'source("R/archive.R")'
- name: Commit results
run: |
git config --local user.email "[email protected]"
git config --local user.name "GitHub Actions"
git add -A
git commit -m 'Data archived' || echo "No changes to commit"
git push origin || echo "No changes to commit"