name: Build IP lists

permissions:
    contents: read

on:
    repository_dispatch:
        types: run-build-lists
    workflow_dispatch:
    schedule:
        - cron: "30 0 */5 * *"

jobs:
    build-aws-cloudfront:
        runs-on: ubuntu-latest
        steps:
            - name: Checkout
              uses: actions/checkout@v4
            - name: Build the AWS CloudFront list
              run: ./make-aws-cloudfront-range.sh
            - name: Post the summary
              run: |
                git add -A
                printf '### Diff\n```diff\n%s\n```\n' "$(git diff --staged)" >> $GITHUB_STEP_SUMMARY
