From 34541b34a6ada55886b7593cfb12d78fa09841c6 Mon Sep 17 00:00:00 2001 From: Enrico Minack Date: Tue, 24 Oct 2023 18:05:24 +0200 Subject: [PATCH] Allow to triger for subset of branches --- .github/workflows/publish_snapshot.yml | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/.github/workflows/publish_snapshot.yml b/.github/workflows/publish_snapshot.yml index 82ed295bc45ae..6d55f1afed0fc 100644 --- a/.github/workflows/publish_snapshot.yml +++ b/.github/workflows/publish_snapshot.yml @@ -23,6 +23,12 @@ on: schedule: - cron: '0 0 * * *' workflow_dispatch: + inputs: + branch: + description: 'list of branches to publish (JSON)' + required: true + # keep in sync with default value of strategy matrix 'branch' + default: '["master", "branch-3.5", "branch-3.4", "branch-3.3"]' jobs: publish-snapshot: @@ -31,11 +37,8 @@ jobs: strategy: fail-fast: false matrix: - branch: - - master - - branch-3.5 - - branch-3.4 - - branch-3.3 + # keep in sync with default value of workflow_dispatch input 'branch' + branch: ${{ fromJSON( inputs.branch || '["master", "branch-3.5", "branch-3.4", "branch-3.3"]' ) }} steps: - name: Checkout Spark repository uses: actions/checkout@v3