From eda8652828eb66bb61932fa3246055003c0de755 Mon Sep 17 00:00:00 2001 From: multipleof4 Date: Mon, 21 Sep 2026 12:53:50 -0700 Subject: [PATCH] Run mirror cleanup at 08:00 UTC daily --- .github/workflows/rename-gone-mirrors.yml | 16 +--------------- 1 file changed, 1 insertion(+), 15 deletions(-) diff --git a/.github/workflows/rename-gone-mirrors.yml b/.github/workflows/rename-gone-mirrors.yml index 65fa1c1..2df550f 100644 --- a/.github/workflows/rename-gone-mirrors.yml +++ b/.github/workflows/rename-gone-mirrors.yml @@ -4,31 +4,17 @@ on: workflow_dispatch: schedule: - cron: '0 8 * * *' # 3 AM CDT - - cron: '0 9 * * *' # 3 AM CST jobs: rename: runs-on: ubuntu-latest steps: - - name: Check Central time - id: central - if: github.event_name == 'schedule' - env: - SCHEDULE: ${{ github.event.schedule }} - run: | - hour=$(echo "$SCHEDULE" | cut -d' ' -f2) - if [ "$(TZ=America/Chicago date -d "$(date -u +%F) ${hour}:00 UTC" +%H)" = 03 ]; then - echo 'run=true' >> "$GITHUB_OUTPUT" - fi - uses: actions/checkout@v4 - if: ${{ github.event_name == 'workflow_dispatch' || steps.central.outputs.run == 'true' }} - uses: actions/setup-node@v4 - if: ${{ github.event_name == 'workflow_dispatch' || steps.central.outputs.run == 'true' }} with: node-version: 20 - name: Rename mirrors missing on GitHub id: sync - if: ${{ github.event_name == 'workflow_dispatch' || steps.central.outputs.run == 'true' }} run: node rename-gone-mirrors.js env: GH_PAT: ${{ secrets.GH_PAT }} @@ -36,7 +22,7 @@ jobs: GITEA_URL: ${{ secrets.GITEA_URL }} - name: Notify via ntfy - if: ${{ always() && (github.event_name == 'workflow_dispatch' || steps.central.outputs.run == 'true') }} + if: ${{ always() }} run: node notify.js env: NTFY_TOPIC_URL: ${{ secrets.NTFY_TOPIC_URL }}