Change bumper workflows

This commit is contained in:
Victor Carlos Erenu
2026-04-14 22:50:41 +07:00
parent 0465f44c14
commit c8e04c1cfd
2 changed files with 15 additions and 45 deletions
+4 -11
View File
@@ -14,11 +14,6 @@ on:
default: ''
required: false
type: string
tag:
description: 'Change branches references to tag-like references (e.g. v4.12.0-alpha7)'
default: false
required: false
type: boolean
issue-link:
description: 'Issue link in format https://github.com/wazuh/<REPO>/issues/<ISSUE-NUMBER>'
required: true
@@ -81,18 +76,16 @@ jobs:
env:
VERSION: ${{ inputs.version }}
STAGE: ${{ inputs.stage }}
TAG: ${{ inputs.tag }}
run: |
script_params=""
version=${{ env.VERSION }}
stage=${{ env.STAGE }}
tag=${{ env.TAG }}
# Both version and stage provided
if [[ -n "$version" && -n "$stage" && "$tag" != "true" ]]; then
if [[ -n "$version" && -n "$stage" ]]; then
script_params="--version ${version} --stage ${stage}"
elif [[ -n "$version" && -n "$stage" && "$tag" == "true" ]]; then
script_params="--version ${version} --stage ${stage} --tag ${tag}"
elif [[ -z "$version" && -n "$stage" ]]; then
script_params="--stage ${stage}"
fi
issue_number=$(echo "${{ inputs.issue-link }}" | awk -F'/' '{print $NF}')
@@ -139,4 +132,4 @@ jobs:
echo "Branch: ${{ steps.vars.outputs.branch_name }}"
echo "PR: ${{ steps.create_pr.outputs.pull_request_url }}"
echo "Bumper scripts logs:"
cat ${BUMP_LOG_PATH}/repository_bumper*log
cat ${BUMP_LOG_PATH}/repository_bumper*log