HMCL/.github/workflows/gradle.yml

31 lines
781 B
YAML
Raw Normal View History

2019-12-17 20:03:31 +08:00
name: Java CI
on: [push, pull_request]
2019-12-17 20:03:31 +08:00
jobs:
build:
runs-on: ubuntu-latest
steps:
2022-11-24 12:54:48 +08:00
- uses: actions/checkout@v3
2021-09-08 20:49:32 +08:00
- name: Set up JDK 11
2022-11-24 12:54:48 +08:00
uses: actions/setup-java@v3
2019-12-17 20:03:31 +08:00
with:
2021-09-08 20:49:32 +08:00
distribution: 'zulu'
java-version: '11'
2022-11-24 12:54:48 +08:00
java-package: 'jdk+fx'
2019-12-17 20:03:31 +08:00
- name: Build with Gradle
run: ./gradlew build
env:
MICROSOFT_AUTH_ID: ${{ secrets.MICROSOFT_AUTH_ID }}
MICROSOFT_AUTH_SECRET: ${{ secrets.MICROSOFT_AUTH_SECRET }}
CURSEFORGE_API_KEY: ${{ secrets.CURSEFORGE_API_KEY }}
- name: Get short SHA
run: echo "SHORT_SHA=${GITHUB_SHA::7}" >> $GITHUB_ENV
- name: Upload Artifacts
2022-11-24 12:54:48 +08:00
uses: actions/upload-artifact@v3
with:
name: HMCL-${{ env.SHORT_SHA }}
2021-09-06 20:17:03 +08:00
path: HMCL/build/libs