diff --git a/.github/workflows/cloudflare-preview-forks-build.yml b/.github/workflows/cloudflare-preview-forks-build.yml index 5d9f59ed..77c19eb6 100644 --- a/.github/workflows/cloudflare-preview-forks-build.yml +++ b/.github/workflows/cloudflare-preview-forks-build.yml @@ -78,12 +78,8 @@ jobs: - name: Install dependencies run: npm ci - - name: Lint - run: npm run textlint || { printf "Run 'ddev textlint' locally to fix it.\n\n"; exit 1; } - - - name: Prettier - run: npm run prettier || { printf "\nRun 'ddev prettier' locally to fix it.\n\n"; exit 1; } - + # textlint and prettier run in test.yml. They are left out here so a + # wording or formatting problem doesn't hold back the preview. - name: Build run: npm run build diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 871ee3dc..ab7fab14 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -15,8 +15,10 @@ env: NODE_VERSION: 24 jobs: - build: - timeout-minutes: 15 + # A separate job, so a wording or formatting problem fails this check + # without stopping the build. + lint: + timeout-minutes: 10 runs-on: ubuntu-24.04 steps: - uses: actions/checkout@v7 @@ -28,7 +30,17 @@ jobs: - name: Lint run: npm run textlint || { printf "Run 'ddev textlint' locally to fix it.\n\n"; exit 1; } - name: Prettier + if: ${{ !cancelled() }} run: npm run prettier || { printf "\nRun 'ddev prettier' locally to fix it.\n\n"; exit 1; } + + build: + timeout-minutes: 15 + runs-on: ubuntu-24.04 + steps: + - uses: actions/checkout@v7 + - uses: actions/setup-node@v7 + with: + node-version: ${{ env.NODE_VERSION }} - name: Load Amplitude secrets # Skipped for forked-repo PRs: GitHub Actions never exposes secrets to those # anyway, but this avoids depending on that alone and skips a step that