Skip to content

snap-gtfs

snap-gtfs #454

Workflow file for this run

on:
schedule:
- cron: '0 0 * * *'
push:
branches: [main, master]
pull_request:
branches: [main, master]
name: snap-gtfs
jobs:
snap-gtfs:
runs-on: macOS-latest
env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
R_KEEP_PKG_SOURCE: yes
steps:
- uses: actions/checkout@v2
with:
fetch-depth: '0'
- uses: r-lib/actions/setup-r@v2
with:
r-version: '4.2.1'
use-public-rspm: true
- uses: r-lib/actions/setup-pandoc@v1
- name: Install renv
run: Rscript -e 'install.packages(c("renv"))'
- name: Install packages
run: Rscript -e 'renv::restore()'
- name: Run targets
run: Rscript -e 'targets::tar_make()'
- name: Commit
run: |
git config --global user.name 'asiripanich'
git config --global user.email '[email protected]'
git add README.md README.Rmd
git commit --no-verify -m 'Update README' || echo "No changes to commit"
git add data/gtfs
git commit -m 'GTFS snapshot' || echo "No changes to commit"
git add data/namtang-parking.txt
git commit -m 'Parking snapshot' || echo "No changes to commit"
git add data/namtang-stop.txt
git commit -m 'Stop snapshot' || echo "No changes to commit"
git push || echo "No changes to commit"