Skip to content

Commit 3e1c94e

Browse files
authored
Infra: validate version format before creating draft release (#2091)
This should help us catch the (somewhat common) case where a release gets tagged `xyz` instead of `0.xyz`.
1 parent 282ddfa commit 3e1c94e

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

.github/workflows/new-release.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,12 @@ jobs:
1616
outputs:
1717
upload_url: ${{ steps.create_release.outputs.upload_url }}
1818
steps:
19+
- name: validate version format
20+
run: |
21+
if [[ ! "${{ github.event.inputs.version }}" == *"."* ]]; then
22+
echo "Error: Version must contain a '.'"
23+
exit 1
24+
fi
1925
- name: create release
2026
id: create_release
2127
uses: actions/create-release@v1

0 commit comments

Comments
 (0)