Skip to content

Update to Minecraft v1.21 (#17) #26

Update to Minecraft v1.21 (#17)

Update to Minecraft v1.21 (#17) #26

Workflow file for this run

name: ci
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
permissions:
contents: read
jobs:
build:
name: Build
runs-on: ubuntu-latest
steps:
- name: Checkout Git repo
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Restore Gradle cache
uses: actions/cache@v2
with:
path: ~/.gradle/caches
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*') }}
restore-keys: |
${{ runner.os }}-gradle-
- name: Set up JDK 21
uses: actions/setup-java@v3
with:
distribution: 'microsoft'
java-version: 21
- name: Validate Gradle Wrapper
uses: gradle/wrapper-validation-action@v1
- name: Build with Gradle
run: |
chmod +x gradlew
./gradlew build --stacktrace
- name: Install rename
run: sudo apt-get install -y rename
# This is only needed when using shadow jar
# - name: Rename file
# run: |
# cd ./build/libs/
# rename -f 's/-all//;' '' *
- name: Archive plugin jars on GitHub
uses: actions/upload-artifact@v3
with:
name: AutomaticInventory
path: build/libs