Update CSV #48
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 CSV | |
on: | |
workflow_dispatch: # Allow manual triggering | |
schedule: | |
- cron: "*/5 * * * *" # Run every 5 minutes | |
jobs: | |
update-csv: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v3 | |
- name: Set up Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: "3.x" | |
cache: 'pip' | |
- name: Install dependencies | |
run: pip install -r requirements.txt | |
- name: Run fetch script | |
run: python fetch.py | |
- name: Commit CSV | |
run: | | |
git config --local user.email "[email protected]" | |
git config --local user.name "GitHub Action" | |
git add *.csv | |
git commit -m "Update CSV file" || echo "No change" | |
git push |