-
Notifications
You must be signed in to change notification settings - Fork 75
57 lines (53 loc) · 1.73 KB
/
Copy pathclient.yml
File metadata and controls
57 lines (53 loc) · 1.73 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
# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.
# This workflow will build a Java project with Gradle and cache/restore any dependencies to improve the workflow execution time
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-java-with-gradle
name: AllMusic Client
on:
push:
# Sequence of patterns matched against refs/heads
branches:
- 'releases/**'
# Sequence of patterns matched against refs/tags
tags:
- '*'
permissions:
contents: write
jobs:
build_client:
runs-on: windows-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
submodules: 'true'
- name: Set up JDK 25
uses: actions/setup-java@v4
with:
java-version: '25'
distribution: 'temurin'
- name: Setup Gradle
uses: gradle/actions/setup-gradle@v3
- name: build
shell: cmd
run: |
gradlew :client:buildClient
- name: update
uses: actions/upload-artifact@v4
with:
name: "allmusic_client"
path: build/
- name: Create Pre-release and Upload Assets
if: startsWith(github.ref, 'refs/tags/') && !contains(github.ref_name, 'debug')
uses: softprops/action-gh-release@v1
with:
prerelease: true
tag_name: ${{ github.ref_name }}
name: "Pre-release ${{ github.ref_name }}"
body: "自动构建的预发布版本"
files: |
build/*.jar
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}