From e5e071970ea61385637211d6e5991b93af22f8c3 Mon Sep 17 00:00:00 2001 From: Filip Pospisil Date: Thu, 8 Feb 2024 12:02:17 +0100 Subject: [PATCH] prefix in different step? --- .github/workflows/main.yaml | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/.github/workflows/main.yaml b/.github/workflows/main.yaml index bfd478581..2daad4ab8 100644 --- a/.github/workflows/main.yaml +++ b/.github/workflows/main.yaml @@ -23,20 +23,21 @@ jobs: steps: - name: Check for branch in vscode-uitests-tooling (macos, ubuntu) + id: initjob run: | REPO_URL="https://api.github.com/repos/$USER/vscode-uitests-tooling/branches" RESPONSE=$(curl -s -H "Authorization: Bearer $TOKEN" "$REPO_URL") if ([ $? -ne 0 ]); then - echo "::set-output name=BRANCH_EXISTS::false" + echo "BRANCH_EXISTS=false" >> $GITHUB_OUTPUT fi BRANCH_EXISTS=$(echo "$RESPONSE" | jq -r '.[] | select(.name=="'"$BRANCH"'") | .name') if [ "$BRANCH_EXISTS" == "$BRANCH" ]; then - echo "::set-output name=BRANCH_EXISTS::true" + echo "BRANCH_EXISTS=true" >> $GITHUB_OUTPUT else - echo "::set-output name=BRANCH_EXISTS::false" + echo "BRANCH_EXISTS=false" >> $GITHUB_OUTPUT fi main: @@ -54,14 +55,14 @@ jobs: USER: "${{ github.repository_owner }}" BRANCH: "${{ github.ref_name }}" TOKEN: "${{ secrets.GITHUB_TOKEN }}" - BRANCH_EXISTS: "${{ needs.init.outputs.BRANCH_EXISTS }}" + BRANCH_EXISTS: "${{ BRANCH_EXISTS }}" runs-on: ${{ matrix.os }} needs: [ init ] steps: - name: kill pipeline run: | - echo $BRANCH_EXISTS + echo ${{ steps.initjob.outputs.BRANCH_EXISTS }} KILLER = "${{github.event.pull_request.user.login}}? echo $KILLER