Skip to content

Update Star Counts #133

Update Star Counts

Update Star Counts #133

name: Update Star Counts
on:
schedule:
- cron: '0 3 * * *'
workflow_dispatch: # Optional: manual run button
jobs:
update-file:
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.11' # Or your preferred version
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt # Optional
- name: Run update script
run: python scripts/querystars.py
- name: Commit and push changes
run: |
git config --global user.name "github-actions[bot]"
git config --global user.email "41898282+github-actions[bot]@users.noreply.github.com"
git add .
git commit -m "Update Starcounts: $(date -u +'%Y-%m-%d')" || echo "No changes to commit"
git push
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}