From 6ae5a2308ea4ac609dc83742e3e6cdc80447bac2 Mon Sep 17 00:00:00 2001 From: wpbonelli Date: Sat, 20 Jan 2024 14:10:51 -0500 Subject: [PATCH] ci(dist): allow release workflow dispatch from develop branch (#1566) --- .github/workflows/release_dispatch.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/release_dispatch.yml b/.github/workflows/release_dispatch.yml index 07ccfb8cda6..3037c98698e 100644 --- a/.github/workflows/release_dispatch.yml +++ b/.github/workflows/release_dispatch.yml @@ -73,8 +73,8 @@ jobs: # if branch was provided explicitly via workflow_dispatch, use it if [[ ("${{ github.event_name }}" == "workflow_dispatch") && (-n "${{ inputs.branch }}") ]]; then branch="${{ inputs.branch }}" - # prevent releases from develop or master - if [[ ("$branch" == "develop") || ("$branch" == "master") ]]; then + # prevent releases from master + if [[ "$branch" == "master" ]]; then echo "error: releases may not be triggered from branch $branch" exit 1 fi @@ -144,7 +144,7 @@ jobs: version: ${{ needs.set_options.outputs.version }} pr: name: Draft release PR - if: ${{ github.event_name == 'push' && github.ref_name != 'master' && (github.event_name == 'workflow_dispatch' && inputs.approve == 'true') || (github.event_name != 'workflow_dispatch' && !contains(github.ref_name, 'rc')) }} + if: ${{ github.ref_name != 'master' && ((github.event_name == 'workflow_dispatch' && inputs.approve == 'true') || (github.event_name != 'workflow_dispatch' && !contains(github.ref_name, 'rc'))) }} needs: - set_options - make_dist