diff --git a/.github/workflows/build-and-test-arm-pr.yaml b/.github/workflows/build-and-test-arm-pr.yaml index 62b657d2fb02c..7bcaf3359e45a 100644 --- a/.github/workflows/build-and-test-arm-pr.yaml +++ b/.github/workflows/build-and-test-arm-pr.yaml @@ -2,23 +2,32 @@ name: build-and-test-arm-pr on: pull_request: - types: - - labeled + workflow_dispatch: jobs: build-and-test-arm: - if: ${{ github.event.label.name == 'ARM64' }} runs-on: [self-hosted, linux, ARM64] container: ros:galactic steps: + - name: Check label + if: ${{ github.event.pull_request && !contains(github.event.pull_request.labels.*.name, 'ARM64') }} + run: | + echo "Please add a proper label to run this workflow." + exit 1 + + - name: Checkout repository + uses: actions/checkout@v2 + with: + fetch-depth: 0 + - name: Get modified packages id: get-modified-packages uses: autowarefoundation/autoware-github-actions/get-modified-packages@tier4/proposal - name: Build and test - id: build-and-test + if: ${{ steps.get-modified-packages.outputs.modified-packages != '' }} uses: autowarefoundation/autoware-github-actions/colcon-build-and-test@tier4/proposal with: rosdistro: galactic - build-depends-repos: build_depends.repos target-packages: ${{ steps.get-modified-packages.outputs.modified-packages }} + build-depends-repos: build_depends.repos diff --git a/.github/workflows/build-and-test-pr.yaml b/.github/workflows/build-and-test-pr.yaml index 4928589444040..e754965ba9bd0 100644 --- a/.github/workflows/build-and-test-pr.yaml +++ b/.github/workflows/build-and-test-pr.yaml @@ -11,13 +11,17 @@ jobs: - name: Cancel previous runs uses: styfle/cancel-workflow-action@0.9.1 + - name: Checkout repository + uses: actions/checkout@v2 + with: + fetch-depth: 0 + - name: Get modified packages id: get-modified-packages uses: autowarefoundation/autoware-github-actions/get-modified-packages@tier4/proposal - name: Build and test if: ${{ steps.get-modified-packages.outputs.modified-packages != '' }} - id: build-and-test uses: autowarefoundation/autoware-github-actions/colcon-build-and-test@tier4/proposal with: rosdistro: galactic @@ -29,6 +33,11 @@ jobs: container: ros:galactic needs: build-and-test steps: + - name: Checkout repository + uses: actions/checkout@v2 + with: + fetch-depth: 0 + - name: Get modified packages id: get-modified-packages uses: autowarefoundation/autoware-github-actions/get-modified-packages@tier4/proposal diff --git a/.github/workflows/build-and-test-scheduled.yaml b/.github/workflows/build-and-test-scheduled.yaml index 514a192bd696c..9f5231feb42e1 100644 --- a/.github/workflows/build-and-test-scheduled.yaml +++ b/.github/workflows/build-and-test-scheduled.yaml @@ -14,6 +14,9 @@ jobs: matrix: os: [ubuntu-latest, ARM64] steps: + - name: Checkout repository + uses: actions/checkout@v2 + - name: Get self packages id: get-self-packages uses: autowarefoundation/autoware-github-actions/get-self-packages@tier4/proposal @@ -22,5 +25,5 @@ jobs: uses: autowarefoundation/autoware-github-actions/colcon-build-and-test@tier4/proposal with: rosdistro: galactic - build-depends-repos: build_depends.repos target-packages: ${{ steps.get-self-packages.outputs.self-packages }} + build-depends-repos: build_depends.repos diff --git a/.github/workflows/delete-closed-pr-docs.yaml b/.github/workflows/delete-closed-pr-docs.yaml index 243af060fe855..103009c646ed9 100644 --- a/.github/workflows/delete-closed-pr-docs.yaml +++ b/.github/workflows/delete-closed-pr-docs.yaml @@ -9,6 +9,11 @@ jobs: delete-closed-pr-docs: runs-on: ubuntu-latest steps: + - name: Checkout repository + uses: actions/checkout@v2 + with: + fetch-depth: 0 + - name: Delete closed PR docs uses: autowarefoundation/autoware-github-actions/delete-closed-pr-docs@tier4/proposal with: diff --git a/.github/workflows/deploy-docs.yaml b/.github/workflows/deploy-docs.yaml index 39ad0ff7a7b1f..61fa0667dd9d1 100644 --- a/.github/workflows/deploy-docs.yaml +++ b/.github/workflows/deploy-docs.yaml @@ -11,16 +11,26 @@ on: - "**/*.svg" - "**/*.png" - "**/*.jpg" - pull_request: - types: - - labeled + pull_request_target: + workflow_dispatch: jobs: deploy-docs: runs-on: ubuntu-latest steps: + - name: Check label + if: ${{ github.event.pull_request && !contains(github.event.pull_request.labels.*.name, 'documentation') }} + run: | + echo "Please add a proper label to run this workflow." + exit 1 + + - name: Checkout repository + uses: actions/checkout@v2 + with: + fetch-depth: 0 + ref: ${{ github.event.pull_request.head.sha }} + - name: Deploy docs - if: ${{ github.event.push || github.event.label.name == 'documentation' }} uses: autowarefoundation/autoware-github-actions/deploy-docs@tier4/proposal with: token: ${{ secrets.GITHUB_TOKEN }}