Skip to content

Commit c706428

Browse files
committed
Update workflow
1 parent 73660cc commit c706428

File tree

6 files changed

+23
-78
lines changed

6 files changed

+23
-78
lines changed

.github/workflows/auto-update.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,13 @@ jobs:
1212
runs-on: ubuntu-latest
1313
steps:
1414
- name: Checkout Leaf repository
15-
uses: actions/checkout@v5
15+
uses: actions/checkout@v6
1616
with:
1717
path: 'Leaf'
1818
token: ${{ secrets.GITHUB_TOKEN }}
1919

2020
- name: Checkout Paper repository
21-
uses: actions/checkout@v5
21+
uses: actions/checkout@v6
2222
with:
2323
path: 'Paper'
2424
repository: "PaperMC/Paper"

.github/workflows/build-1218.yml

Lines changed: 10 additions & 57 deletions
Original file line numberDiff line numberDiff line change
@@ -12,76 +12,29 @@ jobs:
1212
runs-on: blacksmith-8vcpu-ubuntu-2204
1313
env:
1414
BUILD_NUMBER: ${{ github.run_number }}
15-
GRADLE_MEMORY: "-Xmx4g -XX:MaxMetaspaceSize=2g"
15+
GRAALVM_ARGS: "-Dgraal.CompilerConfiguration=enterprise -Dgraal.UsePriorityInlining=true -Dgraal.Vectorization=true -Dgraal.OptDuplication=true --add-modules jdk.incubator.vector"
1616
steps:
1717
- name: Checkout repository
18-
uses: actions/checkout@v5
18+
uses: actions/checkout@v6
1919
with:
2020
fetch-depth: 0
2121

22-
- name: Setup Gradle Cache
23-
uses: actions/checkout@v4
22+
- name: Set up GraalVM JDK 21
23+
uses: graalvm/setup-graalvm@v1
2424
with:
25-
path: |
26-
~/.gradle/caches/modules-2
27-
~/.gradle/caches/jars-*
28-
~/.gradle/caches/transforms-*
29-
~/.gradle/wrapper
30-
~/.gradle/build-cache-*
31-
~/.gradle/configuration-cache-*
32-
.gradle/patchCache
33-
.gradle/patched
34-
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties', 'patches/**/*.patch') }}
35-
restore-keys: |
36-
${{ runner.os }}-gradle-
37-
38-
- name: Gradle Cache Cleanup
39-
run: |
40-
mkdir -p ~/.gradle/caches/modules-2
41-
[ -f ~/.gradle/caches/modules-2/modules-2.lock ] && rm -f ~/.gradle/caches/modules-2/modules-2.lock
42-
find ~/.gradle/caches -name "*.lock" -type f -delete || echo "No lock files found"
43-
44-
- name: Setup java
45-
uses: actions/setup-java@v5
46-
with:
47-
distribution: 'temurin'
48-
java-version: '21'
25+
java-version: 21
26+
github-token: "${{ secrets.GITHUB_TOKEN }}"
27+
cache: gradle
4928

5029
- name: Configure Git
5130
run: |
5231
git config --global user.email "[email protected]"
5332
git config --global user.name "Github Actions"
54-
git config --global core.preloadindex true
55-
git config --global core.fscache true
56-
git config --global gc.auto 256
57-
58-
- name: Configure Gradle Properties
59-
run: |
60-
mkdir -p ~/.gradle
61-
echo "org.gradle.caching=true" >> ~/.gradle/gradle.properties
62-
echo "org.gradle.configuration-cache=true" >> ~/.gradle/gradle.properties
63-
echo "org.gradle.configuration-cache.problems=warn" >> ~/.gradle/gradle.properties
64-
echo "org.gradle.jvmargs=${{ env.GRADLE_MEMORY }} -Dfile.encoding=UTF-8" >> ~/.gradle/gradle.properties
65-
echo "org.gradle.parallel=true" >> ~/.gradle/gradle.properties
66-
echo "org.gradle.daemon=true" >> ~/.gradle/gradle.properties
67-
# This is only need if we create custom gradle.properies in home directory
68-
echo "leafUsername=${{ secrets.REPO_USER }}" >> ~/.gradle/gradle.properties
69-
echo "leafPassword=${{ secrets.REPO_PASSWORD }}" >> ~/.gradle/gradle.properties
7033
7134
- name: Apply patches
72-
run: |
73-
PARALLELISM=$(($(nproc) * 2))
74-
./gradlew -Dorg.gradle.jvmargs="${{ env.GRADLE_MEMORY }}" \
75-
-Dleaf.patcher.parallelism=$PARALLELISM \
76-
-Dleaf.patcher.incremental=true \
77-
applyAllPatches \
78-
--stacktrace --parallel \
79-
--max-workers=$PARALLELISM \
80-
--build-cache \
81-
--no-daemon
82-
35+
run: ./gradlew -Dorg.gradle.jvmargs="${{ env.GRAALVM_ARGS }}" applyAllPatches --stacktrace --no-daemon
8336
- name: Create MojmapPaperclipJar
84-
run: ./gradlew createMojmapPaperclipJar --stacktrace --parallel --no-daemon
37+
run: ./gradlew -Dorg.gradle.jvmargs="${{ env.GRAALVM_ARGS }}" createMojmapPaperclipJar --stacktrace --no-daemon
8538

8639
- name: Prepare release notes and artifacts
8740
run: |
@@ -93,7 +46,7 @@ jobs:
9346
BUILD_NUMBER: ${{ env.BUILD_NUMBER }}
9447

9548
- name: Upload Leaf
96-
uses: actions/upload-artifact@v5
49+
uses: actions/upload-artifact@v6
9750
with:
9851
name: Leaf 1.21.8
9952
path: ./leaf-1.21.8-${{ env.BUILD_NUMBER }}.jar

.github/workflows/build-pr.yml

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,13 +14,14 @@ jobs:
1414

1515
steps:
1616
- name: Checkout repository
17-
uses: actions/checkout@v5
17+
uses: actions/checkout@v6
1818

19-
- name: Setup java
20-
uses: actions/setup-java@v5
19+
- name: Set up GraalVM JDK 21
20+
uses: graalvm/setup-graalvm@v1
2121
with:
22-
distribution: 'temurin'
23-
java-version: '21'
22+
java-version: 21
23+
github-token: "${{ secrets.GITHUB_TOKEN }}"
24+
cache: gradle
2425

2526
- name: Grant execute permission for gradlew
2627
run: chmod +x gradlew
@@ -38,7 +39,7 @@ jobs:
3839
run: |
3940
mv leaf-server/build/libs/leaf-paperclip-1.21.8-R0.1-SNAPSHOT-mojmap.jar ./leaf-1.21.8.jar
4041
- name: Upload Leaf as build artifact
41-
uses: actions/upload-artifact@v5
42+
uses: actions/upload-artifact@v6
4243
with:
4344
name: Leaf 1.21.8
4445
path: ./leaf-1.21.8.jar

.github/workflows/publish-api.yml

Lines changed: 3 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,10 @@ jobs:
1111
runs-on: ubuntu-latest
1212
env:
1313
BUILD_NUMBER: ${{ github.run_number }}
14-
GRADLE_MEMORY: "-Xmx4g -XX:MaxMetaspaceSize=2g"
14+
GRAALVM_ARGS: "-Dgraal.CompilerConfiguration=enterprise -Dgraal.UsePriorityInlining=true -Dgraal.Vectorization=true -Dgraal.OptDuplication=true --add-modules jdk.incubator.vector"
1515
steps:
1616
- name: Checkout repository
17-
uses: actions/checkout@v5
17+
uses: actions/checkout@v6
1818
with:
1919
fetch-depth: 0
2020

@@ -33,16 +33,7 @@ jobs:
3333
git config --global user.name "Github Actions"
3434
3535
- name: Apply patches
36-
run: |
37-
PARALLELISM=$(($(nproc) * 2))
38-
./gradlew -Dorg.gradle.jvmargs="${{ env.GRADLE_MEMORY }}" \
39-
-Dleaf.patcher.parallelism=$PARALLELISM \
40-
-Dleaf.patcher.incremental=true \
41-
applyAllPatches \
42-
--stacktrace --parallel \
43-
--max-workers=$PARALLELISM \
44-
--build-cache \
45-
--no-daemon
36+
run: ./gradlew -Dorg.gradle.jvmargs="${{ env.GRAALVM_ARGS }}" applyAllPatches --stacktrace --no-daemon
4637

4738
- name: Build
4839
run: ./gradlew build -x test

gradle/wrapper/gradle-wrapper.jar

542 Bytes
Binary file not shown.

gradle/wrapper/gradle-wrapper.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionUrl=https\://services.gradle.org/distributions/gradle-9.2.1-bin.zip
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-9.3.0-rc-1-bin.zip
44
networkTimeout=10000
55
validateDistributionUrl=true
66
zipStoreBase=GRADLE_USER_HOME

0 commit comments

Comments
 (0)