From ee06c10f981cf782bd117060b70c416a8097c2e6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcel=20Fabian=20Kr=C3=BCger?= Date: Fri, 22 Mar 2024 23:31:43 +0100 Subject: [PATCH] Autogenerate us file --- .github/workflows/pages.yaml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/pages.yaml b/.github/workflows/pages.yaml index 44a1c93..d1ad762 100644 --- a/.github/workflows/pages.yaml +++ b/.github/workflows/pages.yaml @@ -26,11 +26,12 @@ jobs: url: ${{ steps.deployment.outputs.page_url }} runs-on: ubuntu-latest steps: - - name: Checkout - uses: actions/checkout@v4 - name: Get mirror state run: | podman run ghcr.io/zauguin/get-tl-mirror-status:get-tl-mirror-status > mirrors.json + - name: Generate older 'us' file + run: | + jq -r 'map_values(map_values(to_entries | map(.value.url = .key | .value) | [.[] | select(.status == "Alive")] | group_by(.texlive_version) | INDEX(.[0].texlive_version) | map_values(group_by(.revision) | INDEX(.[0].revision) | map_values(map(.url))) | to_entries | max_by(.key | tonumber).value | to_entries | max_by(.key | tonumber).value)).["North America"].USA.[]' < mirrors.json > us - name: Setup Pages uses: actions/configure-pages@v4 - name: Upload artifact