From a6b2403ff3df3899cc6bac6abb093d7f87d3d09f Mon Sep 17 00:00:00 2001 From: Johann Levesque Date: Wed, 28 Sep 2022 12:00:53 -0400 Subject: [PATCH] Update main.yml --- .github/workflows/main.yml | 38 ++++++++++++++++++++++---------------- 1 file changed, 22 insertions(+), 16 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index c191a89e2a8..19ee302d3eb 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -38,21 +38,27 @@ jobs: exit 1 fi - - name: Develop build for demo files - uses: ./.github/workflows/build.yml - with: - cache_sha: ${{ github.event.pull_request.head.sha || github.sha }} + install-build: + name: Develop build for demo files + needs: [check-member] + uses: ./.github/workflows/build.yml + with: + cache_sha: ${{ github.event.pull_request.head.sha || github.sha }} - - name: Deploy the files for PR - if: github.event.pull_request.merged == false - uses: ./.github/workflows/deploy.yml - with: - cache_sha: ${{ github.event.pull_request.head.sha || github.sha }} - folder: ${{github.head_ref}} + deploy-pr-pages: + name: Deploy the files for PR + needs: [install-build] + if: github.event.pull_request.merged == false + uses: ./.github/workflows/deploy.yml + with: + cache_sha: ${{ github.event.pull_request.head.sha || github.sha }} + folder: ${{github.head_ref}} - - name: Deploy the files on public demo - if: github.event.pull_request.merged == true - uses: ./.github/workflows/deploy.yml - with: - cache_sha: ${{ github.event.pull_request.head.sha || github.sha }} - folder: public + deploy-demo-pages: + name: Deploy the files on public demo + needs: [install-build] + if: github.event.pull_request.merged == true + uses: ./.github/workflows/deploy.yml + with: + cache_sha: ${{ github.event.pull_request.head.sha || github.sha }} + folder: public