-
Notifications
You must be signed in to change notification settings - Fork 0
61 lines (51 loc) · 1.6 KB
/
stable.yml
File metadata and controls
61 lines (51 loc) · 1.6 KB
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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
name: stable
on:
push:
branches:
- main
concurrency:
group: stable
cancel-in-progress: true
jobs:
publish:
runs-on: ubuntu-latest
steps:
- name: Set up Java
uses: actions/setup-java@v2
with:
distribution: adopt
java-version: 21
- name: Checkout code
uses: actions/checkout@v3
- name: Cache Gradle Packages
uses: actions/cache@v4
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }}
restore-keys: ${{ runner.os }}-gradle-
- name: Build
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
chmod +x ./gradlew
./gradlew build
- name: Extract Version
id: get_version
run: echo "version=$(grep 'const val MOD_VERSION' buildSrc/src/main/kotlin/club/asynclab/asyncauth/Props.kt | sed -E 's/.*const val MOD_VERSION = "([^"]+)".*/\1/')" >> $GITHUB_OUTPUT
- name: Generate Changelog
uses: dsx137/generate-changelog@main
id: generate_changelog
with:
exclude: "nightly"
- name: Create GitHub Release
uses: andelf/nightly-release@main
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ steps.get_version.outputs.version }}
name: ${{ steps.get_version.outputs.version }}
prerelease: false
body: ${{ steps.generate_changelog.outputs.changelog }}
files: "**/build/libs/*-all.jar"