Skip to content

update-csv

update-csv #4712

Workflow file for this run

---
name: update-csv
"on":
workflow_dispatch:
schedule:
# At minute 0 past every hour.
- cron: "0 */1 * * *"
permissions:
contents: write
jobs:
update-csv:
runs-on: ubuntu-latest
env:
PYTHON_SPOOF_VENV: ${GITHUB_WORKSPACE}/.venv/bin/python
steps:
- name: Checkout
uses: actions/checkout@v3
with:
submodules: recursive
- name: Reload Cache / pip
uses: actions/setup-python@v4
with:
python-version: 3
update-environment: false
cache: "pip"
cache-dependency-path: |
**/requirements*.txt
- name: Install requirements
run: PYTHON=${{ env.PYTHON_SPOOF_VENV }} make deps
- name: Fetch
run: ./sp --debug fetch
- name: Update standings
run: make output/standings
- name: Update team statistics
run: make output/team-standings
- name: Update playoff projections
run: make output/projections
- name: Update team details
run: make output/team-details
- name: Commit changes (to CSV)
env:
INPUT_AUTHOR_USER_NAME: "github-actions[bot]"
INPUT_AUTHOR_USER_EMAIL: "github-actions[bot]@users.noreply.github.com"
INPUT_COMMIT_USER_NAME: "github-actions[bot]"
INPUT_COMMIT_USER_EMAIL: "github-actions[bot]@users.noreply.github.com"
INPUT_COMMIT_MESSAGE: "Add games to CSV - ${{ github.event.repository.updated_at }}"
uses: stefanzweifel/git-auto-commit-action@v4