Skip to content

Commit

Permalink
Update build action
Browse files Browse the repository at this point in the history
  • Loading branch information
Richy-Z committed May 15, 2024
1 parent 3f18a5f commit 9fd5a49
Show file tree
Hide file tree
Showing 2 changed files with 48 additions and 37 deletions.
48 changes: 48 additions & 0 deletions .github/workflows/build-v2.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
# Automatically build the project and run any configured tests for every push and submitted pull request.
# Provides a first line of defence against bad commits!

# Removed if statement inside capture build artifacts because matrix.java will always be 21.
# Cleaned up the yml file with better formatting and clear separation for better understanding.
name: build
on: [pull_request, push]

jobs:
build:
strategy:
matrix:
java: [21]

runs-on: ubuntu-22.04

steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Validate gradle wrapper
uses: gradle/wrapper-validation-action@v2

- name: Setup JDK ${{ matrix.java }}
uses: actions/setup-java@v4
with:
java-version: ${{ matrix.java }}
distribution: "temurin"

- name: Make gradle wrapper executable
run: chmod +x ./gradlew

- name: Build ThreatenGL
run: ./gradlew build

- name: Bundle mod loader jars for upload
run: |
mkdir gh-artifacts-upload
mv fabric/build/libs/*.jar gh-artifacts-upload/
mv forge/build/libs/*.jar gh-artifacts-upload/
mv neoforge/build/libs/*.jar gh-artifacts-upload/
mv quilt/build/libs/*.jar gh-artifacts-upload/
- name: Upload artifacts
uses: actions/upload-artifact@v4
with:
name: Built Artifacts
path: gh-artifacts-upload/
37 changes: 0 additions & 37 deletions .github/workflows/build.yml

This file was deleted.

0 comments on commit 9fd5a49

Please sign in to comment.