@@ -3,16 +3,24 @@ name: Release
33on :
44 workflow_dispatch :
55 inputs :
6- publish-mod :
7- description : Publish the mod
6+ publish-curseforge :
7+ description : Publish to CurseForge
8+ type : boolean
9+ default : false
10+ publish-modrinth :
11+ description : Publish to Modrinth
12+ type : boolean
13+ default : false
14+ publish-github :
15+ description : Publish to GitHub
816 type : boolean
917 default : false
1018 publish-docs :
1119 description : Publish the web book
1220 type : boolean
1321 default : false
1422 dry-run :
15- description : Dry run
23+ description : Perform a dry run
1624 type : boolean
1725 default : false
1826
3745
3846 publish-mod :
3947 needs : build-docs
40- if : inputs.publish-mod
48+ if : inputs.publish-curseforge || inputs.publish-modrinth || inputs.publish-github
4149 runs-on : ubuntu-latest
4250 environment :
4351 name : curseforge-modrinth
@@ -54,13 +62,26 @@ jobs:
5462 - name : Build mod
5563 run : ./gradlew build
5664
57- - name : Publish mod
65+ - name : Publish to CurseForge
66+ if : inputs.publish-curseforge
5867 env :
5968 DRY_RUN : ${{ inputs.dry-run && 'true' || '' }}
6069 CURSEFORGE_TOKEN : ${{ secrets.CURSEFORGE_TOKEN }}
70+ run : ./gradlew publishCurseforge
71+
72+ - name : Publish to Modrinth
73+ if : inputs.publish-modrinth
74+ env :
75+ DRY_RUN : ${{ inputs.dry-run && 'true' || '' }}
6176 MODRINTH_TOKEN : ${{ secrets.MODRINTH_TOKEN }}
77+ run : ./gradlew publishModrinth
78+
79+ - name : Publish to GitHub
80+ if : inputs.publish-github
81+ env :
82+ DRY_RUN : ${{ inputs.dry-run && 'true' || '' }}
6283 GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
63- run : ./gradlew publishMods
84+ run : ./gradlew publishGithub
6485
6586 - name : Upload dry run artifact
6687 if : inputs.dry-run
0 commit comments