-
Notifications
You must be signed in to change notification settings - Fork 0
45 lines (38 loc) · 1.17 KB
/
publish.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
name: Publish
on:
workflow_dispatch:
pull_request:
types:
- closed
branches:
- master
permissions:
contents: write
jobs:
build:
if: github.event.pull_request.merged == true || github.event_name == 'workflow_dispatch' # @AnthonyWC on GH, https://github.com/orgs/community/discussions/26724#discussioncomment-3253096
runs-on: ubuntu-latest
steps:
- name: Check Environment Variables
run: env
- name: Checkout
uses: actions/checkout@v4
with:
submodules: true
- name: Setup Java
uses: actions/setup-java@v3.12.0
with:
distribution: "temurin"
java-version: 21
- name: Make Gradle Wrapper Executable
if: ${{ runner.os != 'Windows' }}
run: chmod +x ./gradlew
- name: Datagen
run: ./gradlew chiseledRunDatagen
- name: Build and Publish
run: ./gradlew chiseledPublishMods
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
MODRINTH_TOKEN: $${{ secrets.MODRINTH_TOKEN }}
DISCORD_WEBHOOK: $${{ secrets.DISCORD_WEBHOOK }}
DISCORD_WEBHOOK_DRY_RUN: $${{ secrets.DISCORD_WEBHOOK_DRY_RUN }}