diff --git a/.github/workflows/coverage_test.yml b/.github/workflows/coverage_test.yml index f0019ee7e6..bbbf1e403c 100644 --- a/.github/workflows/coverage_test.yml +++ b/.github/workflows/coverage_test.yml @@ -40,6 +40,7 @@ jobs: pytest --cov=astrbot -v -o log_cli=true -o log_level=DEBUG - name: Upload results to Codecov + if: github.repository == 'AstrBotDevs/AstrBot' uses: codecov/codecov-action@v5 with: token: ${{ secrets.CODECOV_TOKEN }} diff --git a/.github/workflows/dashboard_ci.yml b/.github/workflows/dashboard_ci.yml index b6cd9aa2cc..916f43f976 100644 --- a/.github/workflows/dashboard_ci.yml +++ b/.github/workflows/dashboard_ci.yml @@ -8,6 +8,7 @@ on: jobs: build: + if: github.repository == 'AstrBotDevs/AstrBot' runs-on: ubuntu-latest steps: - name: Checkout repository diff --git a/.github/workflows/docker-image.yml b/.github/workflows/docker-image.yml index ccf5604357..f80e8588fd 100644 --- a/.github/workflows/docker-image.yml +++ b/.github/workflows/docker-image.yml @@ -11,7 +11,7 @@ on: jobs: build-nightly-image: - if: github.event_name == 'schedule' + if: github.repository == 'AstrBotDevs/AstrBot' && github.event_name == 'schedule' runs-on: ubuntu-latest env: DOCKER_HUB_USERNAME: ${{ secrets.DOCKER_HUB_USERNAME }} @@ -109,7 +109,7 @@ jobs: run: echo "Test Docker image has been built and pushed successfully" build-release-image: - if: github.event_name == 'workflow_dispatch' || (github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')) + if: github.repository == 'AstrBotDevs/AstrBot' && (github.event_name == 'workflow_dispatch' || (github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v'))) runs-on: ubuntu-latest env: DOCKER_HUB_USERNAME: ${{ secrets.DOCKER_HUB_USERNAME }} diff --git a/.github/workflows/pr-title-check.yml b/.github/workflows/pr-title-check.yml index ff7e79e618..d5faf88a51 100644 --- a/.github/workflows/pr-title-check.yml +++ b/.github/workflows/pr-title-check.yml @@ -6,6 +6,7 @@ on: jobs: title-format: + if: github.repository == 'AstrBotDevs/AstrBot' runs-on: ubuntu-latest permissions: pull-requests: write diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 0cfe182618..09f3c7e27d 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -20,6 +20,7 @@ permissions: jobs: build-dashboard: name: Build Dashboard + if: github.repository == 'AstrBotDevs/AstrBot' runs-on: ubuntu-24.04 env: R2_ACCOUNT_ID: ${{ secrets.R2_ACCOUNT_ID }} @@ -104,6 +105,7 @@ jobs: publish-release: name: Publish GitHub Release + if: github.repository == 'AstrBotDevs/AstrBot' runs-on: ubuntu-24.04 needs: - build-dashboard @@ -183,6 +185,7 @@ jobs: publish-pypi: name: Publish PyPI + if: github.repository == 'AstrBotDevs/AstrBot' runs-on: ubuntu-24.04 needs: - publish-release diff --git a/.github/workflows/stale.yml b/.github/workflows/stale.yml index c6c41a8904..c0ca4978ae 100644 --- a/.github/workflows/stale.yml +++ b/.github/workflows/stale.yml @@ -18,6 +18,7 @@ on: jobs: stale: + if: github.repository == 'AstrBotDevs/AstrBot' runs-on: ubuntu-latest permissions: issues: write diff --git a/.github/workflows/sync-wiki.yml b/.github/workflows/sync-wiki.yml index 2fe0d3153d..78052c2ed8 100644 --- a/.github/workflows/sync-wiki.yml +++ b/.github/workflows/sync-wiki.yml @@ -18,6 +18,7 @@ concurrency: jobs: sync: + if: github.repository == 'AstrBotDevs/AstrBot' runs-on: ubuntu-latest permissions: contents: read