Skip to content

Build Data

Build Data #61

Workflow file for this run

name: Build Data
on:
schedule:
- cron: '0 0 * * *'
push:
branches: [ "main" ]
workflow_dispatch:
permissions:
contents: write
jobs:
build-and-deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.10'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install requests python-dotenv
- name: Run build script
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: python build.py
- name: Check if build/data.json exists
run: |
ls -l build/data.json
- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./build