From a4138cc52334e65bc130ccf7bb97059d0d813858 Mon Sep 17 00:00:00 2001 From: Eduard Dyckman Date: Tue, 22 Aug 2023 14:01:24 +0300 Subject: [PATCH] fix: make branch name matching strict (#30) --- action.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/action.yml b/action.yml index f602391..7de1175 100644 --- a/action.yml +++ b/action.yml @@ -79,8 +79,7 @@ runs: # Get the branch id by its name. We list all branches and filter by name branch_id=$(neonctl branches list --project-id ${{ inputs.project_id }} -o json \ - | jq -c '.[] | select(.name | contains("'${{ inputs.branch_name }}'")) .id' \ - | jq -r) + | jq -r '.[] | select(.name == "${{ inputs.branch_name }}") | .id') echo "branch exists, branch id: ${branch_id}\n" >> debug.log