diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index e7a02ee0cd69..2b0bf82ec337 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -138,10 +138,8 @@ jobs: is_develop: ${{ github.ref == 'refs/heads/develop' }} is_release: ${{ startsWith(github.ref, 'refs/heads/release/') }} is_gitflow_sync: ${{ github.head_ref == 'refs/heads/develop' || github.head_ref == 'refs/heads/master' }} - has_gitflow_label: - ${{ github.event_name == 'pull_request' && contains(steps.pr-labels.outputs.labels, ' Gitflow ') }} - force_skip_cache: - ${{ github.event_name == 'pull_request' && contains(steps.pr-labels.outputs.labels, ' ci-skip-cache ') }} + has_gitflow_label: ${{ github.event_name == 'pull_request' && contains(steps.pr-labels.outputs.labels, ' Gitflow ') }} + force_skip_cache: ${{ github.event_name == 'pull_request' && contains(steps.pr-labels.outputs.labels, ' ci-skip-cache ') }} job_install_deps: name: Install Dependencies @@ -174,8 +172,7 @@ jobs: key: ${{ steps.compute_lockfile_hash.outputs.hash }} - name: Install dependencies - if: - steps.cache_dependencies.outputs.cache-hit == '' || needs.job_get_metadata.outputs.force_skip_cache == 'true' + if: steps.cache_dependencies.outputs.cache-hit == '' || needs.job_get_metadata.outputs.force_skip_cache == 'true' run: yarn install --ignore-engines --frozen-lockfile outputs: dependency_cache_key: ${{ steps.compute_lockfile_hash.outputs.hash }} @@ -218,8 +215,7 @@ jobs: path: node_modules/.cache/nx key: nx-Linux-${{ github.ref }}-${{ env.HEAD_COMMIT }} # On develop branch, we want to _store_ the cache (so it can be used by other branches), but never _restore_ from it - restore-keys: - ${{needs.job_get_metadata.outputs.is_develop == 'false' && env.NX_CACHE_RESTORE_KEYS || 'nx-never-restore'}} + restore-keys: ${{needs.job_get_metadata.outputs.is_develop == 'false' && env.NX_CACHE_RESTORE_KEYS || 'nx-never-restore'}} - name: Build packages # Under normal circumstances, using the git SHA as a cache key, there shouldn't ever be a cache hit on the built @@ -802,7 +798,7 @@ jobs: needs: [job_get_metadata, job_build] runs-on: ubuntu-20.04 timeout-minutes: 30 - if: contains(github.event.pull_request.labels.*.name, 'ci-overhead-measurements') + if: contains(github.event.pull_request.labels.*.name, 'ci-overhead-measurements') || needs.job_get_metadata.outputs.is_develop == 'true' steps: - name: Check out current commit (${{ needs.job_get_metadata.outputs.commit_label }}) uses: actions/checkout@v3