From 91b176a8e421544806eeac6fbb75b5f35decffcf Mon Sep 17 00:00:00 2001 From: Gabe Kangas Date: Thu, 11 Jul 2024 11:47:33 -0700 Subject: [PATCH] Fix checkouts --- .../workflows/automated-end-to-end-api.yaml | 6 +++--- .github/workflows/chromatic.yml | 18 +++++++++--------- .github/workflows/hls-tests.yml | 4 +++- 3 files changed, 15 insertions(+), 13 deletions(-) diff --git a/.github/workflows/automated-end-to-end-api.yaml b/.github/workflows/automated-end-to-end-api.yaml index f07e28885..333c81341 100644 --- a/.github/workflows/automated-end-to-end-api.yaml +++ b/.github/workflows/automated-end-to-end-api.yaml @@ -18,6 +18,9 @@ jobs: with: concurrent_skipping: 'same_content_newer' + - name: Checkout repository + uses: actions/checkout@v4 + - name: Get changed files id: changed-files-yaml uses: tj-actions/changed-files@v44 @@ -43,9 +46,6 @@ jobs: image: tonistiigi/binfmt:latest platforms: all - - uses: actions/checkout@v4 - if: steps.changed-files-yaml.outputs.src_any_changed == 'true' - - name: Run API tests if: steps.changed-files-yaml.outputs.src_any_changed == 'true' uses: nick-fields/retry@v3 diff --git a/.github/workflows/chromatic.yml b/.github/workflows/chromatic.yml index 0b1f87ee3..e6a343f9c 100644 --- a/.github/workflows/chromatic.yml +++ b/.github/workflows/chromatic.yml @@ -28,6 +28,15 @@ jobs: with: concurrent_skipping: 'same_content_newer' + - name: Check out code + if: ${{ github.actor != 'renovate[bot]' && github.actor != 'renovate' && steps.changed-files-yaml.outputs.src_any_changed == 'true' }} + uses: actions/checkout@v4 + with: + # Make sure the actual branch is checked out when running on pull requests + ref: ${{ github.event.pull_request.head.ref }} + repository: ${{ github.event.pull_request.head.repo.full_name }} + fetch-depth: 0 + - name: Get changed files id: changed-files-yaml uses: tj-actions/changed-files@v44 @@ -40,15 +49,6 @@ jobs: src: - '**/*.{js,ts,tsx,jsx,md}' - - name: Check out code - if: ${{ github.actor != 'renovate[bot]' && github.actor != 'renovate' && steps.changed-files-yaml.outputs.src_any_changed == 'true' }} - uses: actions/checkout@v4 - with: - # Make sure the actual branch is checked out when running on pull requests - ref: ${{ github.event.pull_request.head.ref }} - repository: ${{ github.event.pull_request.head.repo.full_name }} - fetch-depth: 0 - - name: Install dependencies if: ${{ github.actor != 'renovate[bot]' && github.actor != 'renovate' && steps.changed-files-yaml.outputs.src_any_changed == 'true'}} run: npm install diff --git a/.github/workflows/hls-tests.yml b/.github/workflows/hls-tests.yml index 42b1b8f54..d5d35ed49 100644 --- a/.github/workflows/hls-tests.yml +++ b/.github/workflows/hls-tests.yml @@ -25,6 +25,9 @@ jobs: with: concurrent_skipping: 'same_content_newer' + - name: Checkout repository + uses: actions/checkout@v4 + - name: Get changed files id: changed-files-yaml uses: tj-actions/changed-files@v44 @@ -33,7 +36,6 @@ jobs: src: - '**/*.{go,mod,sum}' - - uses: actions/checkout@v4 - uses: actions/setup-go@v5 if: steps.changed-files-yaml.outputs.src_any_changed == 'true' with: