Skip to content

Commit

Permalink
CI test
Browse files Browse the repository at this point in the history
  • Loading branch information
Faboslav committed Jan 15, 2024
1 parent 6534d80 commit 73e190a
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 22 deletions.
21 changes: 7 additions & 14 deletions .github/actions/setup-environment/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,24 +4,17 @@ runs:
using: "composite"
steps:
- name: "Checkout repository"
uses: actions/checkout@v3.5.3
uses: actions/checkout@v4.1.1
with:
fetch-depth: 0

- name: "Set up JDK"
uses: actions/setup-java@v3.12.0
uses: actions/setup-java@v4.0.0
with:
distribution: "temurin"
java-version: 17
cache: gradle
distribution: temurin

- name: "Initialize caches"
uses: actions/[email protected]
with:
path: |
~/.gradle/caches
~/.gradle/loom-cache
~/.gradle/wrapper
key: ${{ runner.os }}-build-${{ hashFiles('gradle/wrapper/gradle-wrapper.properties') }}
restore-keys: |
${{ runner.os }}-build-
- name: "Setup Gradle"
uses: gradle/[email protected]
with:
cache-read-only: true
25 changes: 17 additions & 8 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,20 +12,29 @@ on:
jobs:
build:
runs-on: ubuntu-latest

name: "Build"
timeout-minutes: 15
timeout-minutes: 10

steps:
- name: "Checkout repository"
uses: actions/checkout@v3.5.3
uses: actions/checkout@v4.1.1
with:
fetch-depth: 0

- name: "Setup environment"
uses: ./.github/actions/setup-environment
- name: "Set up JDK"
uses: actions/[email protected]
with:
java-version: 17
distribution: temurin

- name: "Setup Gradle"
uses: gradle/[email protected]
with:
cache-read-only: false

- name: "Build with gradle"
run: ./gradlew build
- name: "Run Gradle build"
run: ./gradlew build --no-daemon

run-client:
needs: build
Expand All @@ -35,7 +44,7 @@ jobs:
matrix:
mod_loader: [ "fabric", "forge" ]
name: Run ${{ matrix.mod_loader }} client
timeout-minutes: 15
timeout-minutes: 10

steps:
- name: "Checkout repository"
Expand All @@ -60,7 +69,7 @@ jobs:
matrix:
mod_loader: [ "fabric", "forge" ]
name: Run ${{ matrix.mod_loader }} server
timeout-minutes: 15
timeout-minutes: 10

steps:
- name: "Checkout repository"
Expand Down

0 comments on commit 73e190a

Please sign in to comment.