File tree Expand file tree Collapse file tree 2 files changed +16
-10
lines changed
Expand file tree Collapse file tree 2 files changed +16
-10
lines changed Original file line number Diff line number Diff line change 55set -e
66
77# Determine version and release type
8- if [[ " ${{ github.event_name } }" == " workflow_dispatch" ]]; then
9- VERSION=" ${{ github.event.inputs.version } }"
10- RELEASE_TYPE=" ${{ github.event.inputs.release_type } }"
11- elif [[ " ${{ github.event_name } }" == " push" && " ${{ github.ref_type } }" == " tag" ]]; then
12- VERSION=" ${{ github.ref_name } }"
8+ if [[ " $EVENT_NAME " == " workflow_dispatch" ]]; then
9+ VERSION=" $INPUT_VERSION "
10+ elif [[ " $EVENT_NAME " == " push" && " $REF_TYPE " == " tag" ]]; then
11+ VERSION=" $REF_NAME "
1312 VERSION=" ${VERSION# v} "
14- if [[ " $VERSION " == * " -rc" * ]]; then
15- RELEASE_TYPE=" rc"
16- else
17- RELEASE_TYPE=" stable"
18- fi
13+ fi
14+
15+ # Determine release type based on version string
16+ if [[ " $VERSION " == * " -rc" * ]]; then
17+ RELEASE_TYPE=" rc"
18+ else
19+ RELEASE_TYPE=" stable"
1920fi
2021
2122# Validate version format
Original file line number Diff line number Diff line change 3131 run : |
3232 chmod +x .github/scripts/release/*.sh
3333 .github/scripts/release/setup-release-vars.sh
34+ env :
35+ EVENT_NAME : ${{ github.event_name }}
36+ INPUT_VERSION : ${{ github.event.inputs.version }}
37+ REF_TYPE : ${{ github.ref_type }}
38+ REF_NAME : ${{ github.ref_name }}
3439
3540 - name : Build
3641 run : .github/scripts/release/build-and-test.sh
You can’t perform that action at this time.
0 commit comments