Skip to content

Update List Data

Update List Data #68

Workflow file for this run

name: Update List Data
on:
schedule:
- cron: '0 12 * * *'
workflow_dispatch:
jobs:
update-data:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/checkout@v4
- name: Fetch list and save to data/list.json
run: |
# Create data directory if it doesn't exist
mkdir -p data
# Fetch raw JSON and save it directly
curl -sSf https://raw.githubusercontent.com/kebab-os/list/refs/heads/main/list.json -o data/list.json
# Validate JSON
python3 -c "import json; json.load(open('data/list.json'))"
- name: Commit and push changes
run: |
git config user.name "github-actions[bot]"
git config user.email "github-actions[bot]@users.noreply.github.com"
git add data/list.json
git diff --cached --quiet || git commit -m "chore: update list data"
git push