Skip to content

Commit 3bdbcb8

Browse files
committed
sdfdw
1 parent f3a0020 commit 3bdbcb8

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

.github/workflows/create-new-version.yml

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,14 @@ name: 'Create new version'
33
on:
44
workflow_dispatch:
55
inputs:
6-
version:
7-
description: 'Select the type of version to create'
6+
minor:
7+
description: 'Minor version number'
8+
type: number
9+
required: true
10+
major:
11+
description: 'Major version number'
12+
type: number
813
required: true
9-
type: choice
10-
options:
11-
- 'Breaking changes'
12-
- 'Minor update'
1314

1415
permissions:
1516
actions: read
@@ -24,12 +25,10 @@ concurrency:
2425
jobs:
2526
versioning:
2627
name: 'Determine version'
27-
needs: [workflow-variables]
2828
runs-on: ubuntu-latest
2929

3030
outputs:
31-
major: ${{ inputs.version == 'Breaking changes' && fromJson(env.major + 1) || fromJson(env.major) }}
32-
minor: ${{ inputs.version == 'Minor update' && fromJson(env.minor + 1) || fromJson(env.minor) }}
31+
is-breaking-change: ${{ inputs.major > steps.versioning.outputs.major }}
3332

3433
steps:
3534
- name: 'Checkout ${{ github.head_ref || github.ref }}'
@@ -51,5 +50,6 @@ jobs:
5150
run: |
5251
echo "major: ${{ steps.versioning.outputs.major }}"
5352
echo "minor: ${{ steps.versioning.outputs.minor }}"
53+
echo "is-breaking-change: ${{ steps.versioning.outputs.is-breaking-change }}"
5454
5555

0 commit comments

Comments
 (0)