File tree Expand file tree Collapse file tree 1 file changed +11
-2
lines changed Expand file tree Collapse file tree 1 file changed +11
-2
lines changed Original file line number Diff line number Diff line change 50
50
51
51
# Increment versions by the specified input values
52
52
new_major=$((major + ${{ github.event.inputs.increment_major }}))
53
- new_minor=$((minor + ${{ github.event.inputs.increment_minor }}))
54
- new_patch=$((patch + ${{ github.event.inputs.increment_patch }}))
53
+ if [ ${{ github.event.inputs.increment_major }} -gt 0 ]; then
54
+ new_minor="${{ github.event.inputs.increment_minor }}"
55
+ new_patch="${{ github.event.inputs.increment_patch }}"
56
+ else
57
+ new_minor=$((minor + ${{ github.event.inputs.increment_minor }}))
58
+ if [ ${{ github.event.inputs.increment_minor }} -gt 0 ]; then
59
+ new_patch="${{ github.event.inputs.increment_patch }}"
60
+ else
61
+ new_patch=$((patch + ${{ github.event.inputs.increment_patch }}))
62
+ fi
63
+ fi
55
64
56
65
# Construct the new version string
57
66
new_version="$new_major.$new_minor.$new_patch"
You can’t perform that action at this time.
0 commit comments