Update Data Workflow #231
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: Update Data Workflow | |
on: | |
schedule: | |
- cron: '0 10 * * *' # Run every day at 10:00 UTC | |
workflow_dispatch: # Allows manual triggering of the workflow | |
jobs: | |
update-data: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
token: ${{ secrets.PAT }} | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.11.8' | |
- name: Install dependencies | |
run: | | |
pip install pandas gspread oauth2client | |
- name: Write credentials to file | |
run: | | |
echo '${{ secrets.GOOGLE_CREDENTIALS }}' > omoku-analysis-cred_key.json | |
env: | |
GOOGLE_CREDENTIALS: ${{ secrets.GOOGLE_CREDENTIALS }} | |
- name: Run the update script | |
run: python update_data.py |