This repository has been archived by the owner on Jul 16, 2024. It is now read-only.
forked from Up-Mods/LibZoomer
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
25 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,24 +1,40 @@ | ||
name: Java CI with Gradle | ||
name: Build | ||
|
||
on: [ pull_request, push ] | ||
on: [ pull_request, push, workflow_dispatch ] | ||
|
||
jobs: | ||
build: | ||
Build: | ||
runs-on: ubuntu-22.04 | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Get github short hash | ||
id: github_short_hash | ||
run: echo "result=$(git rev-parse --short "${{ github.sha }}")" >> $GITHUB_OUTPUT | ||
- name: Set up JDK 17 | ||
uses: actions/setup-java@v3 | ||
with: | ||
distribution: 'temurin' | ||
java-version: 17 | ||
- name: Grant execute permission for Gradlew | ||
run: chmod +x gradlew | ||
- name: Cache | ||
uses: actions/cache@v3 | ||
with: | ||
path: | | ||
~/.gradle/caches | ||
~/.gradle/wrapper | ||
.gradle | ||
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties', 'build.gradle') }} | ||
- name: Build with Gradle | ||
run: ./gradlew build | ||
- name: Upload build artifacts | ||
run: | | ||
chmod +x gradlew | ||
./gradlew build | ||
- name: Upload artifacts (fabric) | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: Artifacts-fabric | ||
path: ${{ github.workspace }}/fabric/build/libs | ||
- name: Upload artifacts (forge) | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: Artifacts | ||
path: build/libs | ||
name: Artifacts-forge | ||
path: ${{ github.workspace }}/forge/build/libs |