Skip to content

Commit 7610393

Browse files
committed
try to use expr for inputs validation
1 parent d54a8a9 commit 7610393

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

.github/workflows/release.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,11 +16,11 @@ jobs:
1616
steps:
1717
- name: "Check release version"
1818
run: |
19-
[ "${{ github.event.inputs.releaseVersion }}" '=~' '^[0-9]+\.[0-9]+\.[0-9]+$' ]
19+
expr "${{ github.event.inputs.releaseVersion }}" : '[[:digit:]][[:digit:]]*\.[[:digit:]][[:digit:]]*\.[[:digit:]][[:digit:]]*$'
2020
2121
- name: "Check next version"
2222
run: |
23-
[ "${{ github.event.inputs.nextVersion }}" '=~' '^[0-9]+\.[0-9]+$' ]
23+
expr "${{ github.event.inputs.nextVersion }}" : '[[:digit:]][[:digit:]]*\.[[:digit:]][[:digit:]]*$'
2424
2525
- uses: actions/checkout@v2.3.4
2626
with:

0 commit comments

Comments
 (0)