Skip to content

Commit f12de4e

Browse files
committed
fix releasing alias
1 parent 813c952 commit f12de4e

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

.github/workflows/release.yml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,6 @@ jobs:
2929
run: pnpx zardoy-release empty --skip-github --output-file assets/release.json
3030
env:
3131
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
32-
- name: Get releasing alias
33-
run: node scripts/githubActions.mjs getReleasingAlias
34-
id: alias
3532
- name: Download Generated Sounds map
3633
run: node scripts/downloadSoundsMap.mjs
3734
- run: vercel build --token=${{ secrets.VERCEL_TOKEN }} --prod
@@ -48,8 +45,10 @@ jobs:
4845
with:
4946
run: vercel deploy --prebuilt --token=${{ secrets.VERCEL_TOKEN }} --prod
5047
id: deploy
48+
- name: Get releasing alias
49+
run: node scripts/githubActions.mjs getReleasingAlias
50+
id: alias
5151
- name: Set deployment alias
52-
if: ${{ steps.alias.outputs.alias != '' && steps.alias.outputs.alias != 'mcraft.fun' && steps.alias.outputs.alias != 's.mcraft.fun' }}
5352
run: |
5453
for alias in $(echo ${{ steps.alias.outputs.alias }} | tr "," "\n"); do
5554
vercel alias set ${{ steps.deploy.outputs.stdout }} $alias --token=${{ secrets.VERCEL_TOKEN }} --scope=zaro

scripts/githubActions.mjs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,10 @@ const fns = {
2222
const tag = releaseJson.latestTag
2323
const [major, minor, patch] = tag.replace('v', '').split('.')
2424
if (major === '0' && minor === '1') {
25-
return final(`v${patch}`)
25+
setOutput('alias', final(`v${patch}`))
26+
} else {
27+
setOutput('alias', final(tag))
2628
}
27-
return final(tag)
2829
}
2930
}
3031

0 commit comments

Comments
 (0)