Skip to content

Commit a57f828

Browse files
authored
Mark the release as a prerelease if it has a - in its name. (#84)
1 parent 6f6d1d9 commit a57f828

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

.github/workflows/publish.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -142,15 +142,15 @@ jobs:
142142
run: |
143143
set -x
144144
# If it's not a simple 1.2.3 version, then it's a prerelease of some kind.
145-
if ! [[ ${{ github.event.release.tag_name }} =~ ^[0-9.]*$ ]] ; then
145+
if [[ ${{ github.event.release.tag_name }} =~ .*-.* ]] ; then
146146
PRE="--prerelease"
147147
fi
148148
node publish.js --publish "${PRE}"
149149
- name: Finalize GitHub release
150150
uses: ncipollo/release-action@v1
151151
with:
152152
token: ${{ secrets.WORKFLOW_PAT }}
153-
prerelease: false
153+
prerelease: ${{ contains(github.event.release.name, '-') }}
154154
allowUpdates: true
155155
tag: ${{ github.event.release.tag_name }}
156156
name: ${{ github.event.release.name }}

0 commit comments

Comments
 (0)