diff --git a/.github/workflows/website.yaml b/.github/workflows/website.yaml index bf18212c5..70dbf2a7a 100644 --- a/.github/workflows/website.yaml +++ b/.github/workflows/website.yaml @@ -66,10 +66,13 @@ concurrency: cancel-in-progress: true env: + # workflow + HAS_ROOT_REPO_CONTEXT: ${{ github.event_name != 'pull_request' }} + # client STEAM_USERNAME: ${{ secrets.STEAM_USERNAME }} STEAM_PASSWORD: ${{ secrets.STEAM_PASSWORD }} - CLIENT_PROVIDER: ${{ inputs.client_provider || 'wgc' }} + CLIENT_PROVIDER: ${{ inputs.client_provider || (github.event_name != 'pull_request' && 'steam' || 'wgc') }} CLIENT_SOURCE: ${{ inputs.client_source || '444200/windows' }} CLIENT_DIR: ../../temp/game @@ -90,9 +93,6 @@ env: # wargaming PUBLIC_WARGAMING_APPLICATION_ID: ${{ secrets.PUBLIC_WARGAMING_APPLICATION_ID }} - # workflow - SHOULD_USE_BLITZKIT_CLOSED: ${{ github.event_name != 'pull_request' }} - jobs: build: name: Build website @@ -119,7 +119,7 @@ jobs: # we need to handle them here instead of disabling submodules outright - name: Checkout submodules run: | - if [ "$SHOULD_USE_BLITZKIT_CLOSED" = "true" ]; then + if [ "$HAS_ROOT_REPO_CONTEXT" = "true" ]; then git submodule update --init --recursive --depth=1 else git submodule update --init --recursive --depth=1 -- . ':!packages/closed' @@ -148,7 +148,7 @@ jobs: run: scripts/download-client.sh - name: Download SmartDLC - if: ${{ env.SHOULD_USE_BLITZKIT_CLOSED == 'true' }} + if: ${{ env.HAS_ROOT_REPO_CONTEXT == 'true' }} run: scripts/download-smart-dlc.sh - name: Build @@ -171,7 +171,8 @@ jobs: # - is by manual and is on anything: triggering to anything if: >- ${{ - (github.event_name == 'schedule' && github.ref == 'refs/heads/main') + env.HAS_ROOT_REPO_CONTEXT == 'true' + || (github.event_name == 'schedule' && github.ref == 'refs/heads/main') || (github.event_name == 'push' && github.ref == 'refs/heads/production') || (github.event_name == 'workflow_dispatch') }}