Skip to content

Daily update from GSheet #553

Daily update from GSheet

Daily update from GSheet #553

name: Daily update from GSheet
on:
workflow_dispatch:
schedule:
- cron: '0 2,14 * * *'
permissions:
contents: write
jobs:
update:
name: Daily update from the Google Spreadsheet
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up environment
uses: actions/setup-python@v4
with:
python-version: 3.11
- name: Install dependencies
run: pip3 install --user requests
- name: Get snapshot from GSheet
run: python3 scripts/get_snapshot.py
- name: Update Git repository
run: |
git config user.name "Auto updater"
git config user.email github-actions@github.com
git add data/
git commit -m "Auto update $(date +'%Y-%m-%d')" || true
git push origin ${GITHUB_REF_NAME}