-
Notifications
You must be signed in to change notification settings - Fork 10
29 lines (29 loc) · 1.47 KB
/
gradle.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
name: 'Build Commit'
on:
push:
branches:
- '[0-9]**'
paths-ignore:
- '*.md'
- 'LICENSE'
- '.github/**'
- '.gitignore'
tags-ignore:
- '[0-9]+.[0-9]+.[0-9]+-[0-9]+.[0-9]+.[0-9]+'
- '[0-9]+.[0-9]+-[0-9]+.[0-9]+.[0-9]+'
jobs:
build:
runs-on: ubuntu-latest
steps:
- { uses: actions/checkout@v2, with: { fetch-depth: 0 } }
- { name: 'Set up JDK 17', uses: actions/setup-java@v2, with: { distribution: 'adopt', java-version: '17' } }
- uses: burrunan/gradle-cache-action@v1
name: Build with Gradle
id: build
env:
USE_ALPHAS: true
with:
arguments: "setupGithubActions build"
gradle-version: "wrapper"
- { name: 'Create a Release', id: create_release, uses: meeDamian/github-release@2.0, with: { token: '${{ secrets.GITHUB_TOKEN }}', tag: 'alpha-${{ steps.build.outputs.version }}', name: '${{ steps.build.outputs.modid }}-alpha-${{ steps.build.outputs.version }}', draft: false, prerelease: true, commitish: '${{ github.sha }}', files: 'fabric/build/libs/${{ steps.build.outputs.modid }}-${{ steps.build.outputs.version }}-fabric.jar forge/build/libs/${{ steps.build.outputs.modid }}-${{ steps.build.outputs.version }}-forge.jar', gzip: false } }
- { name: 'Push Changelog to Discord', id: changelog-webhook, uses: itsmeow/webhook-action@master, env: { WEBHOOK_URL: '${{ secrets.DISCORD_WEBHOOK_URL }}', data: '${{ steps.build.outputs.commitlog }}' } }