This repository has been archived by the owner on Jan 27, 2025. It is now read-only.
Daily Homicide Data Sync #1847
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Daily Homicide Data Sync | |
on: | |
schedule: | |
- cron: "15 15 * * 1-5" | |
- cron: "15 17 * * 1-5" | |
push: | |
paths: | |
- .github/workflows/daily-homicide-sync.yml | |
jobs: | |
daily-sync-homicides: | |
name: Daily Homicides Data Sync | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
persist-credentials: false | |
fetch-depth: 0 | |
- uses: actions/setup-python@v2 | |
with: | |
python-version: "3.9" | |
- name: Run image | |
uses: abatilo/actions-poetry@v2.0.0 | |
with: | |
poetry-version: "1.4.2" | |
- name: Install dependencies | |
run: sudo apt-get install -y libspatialindex-dev | |
- name: Run update | |
run: | | |
poetry install | |
git pull origin master | |
poetry run gv-dashboard-data daily-update --homicides-only | |
- name: Commit files | |
continue-on-error: true | |
run: | | |
git config --local user.email "action@github.com" | |
git config --local user.name "GitHub Action" | |
git commit -a -m "Add daily download changes" | |
- name: Push changes | |
uses: ad-m/github-push-action@master | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} |