Skip to content

Commit 2e115d8

Browse files
committed
Port to MC 1.20
1 parent 8844ec5 commit 2e115d8

34 files changed

+322
-221
lines changed

Jenkinsfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ pipeline {
3131
]) {
3232

3333
echo 'Building project.'
34-
sh './gradlew build publish publishCurseForge updateVersionTracker postDiscord --stacktrace --warn'
34+
sh './gradlew build publish publishCurseForge modrinth updateVersionTracker postDiscord --stacktrace --warn'
3535
}
3636
}
3737
}

build.gradle

Lines changed: 13 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,15 @@ buildscript {
1212
}
1313
}
1414

15+
plugins {
16+
id 'fabric-loom' version '1.2-SNAPSHOT' apply(false)
17+
id 'net.minecraftforge.gradle' version '[6.0,6.2)' apply(false)
18+
id 'org.spongepowered.gradle.vanilla' version '0.2.1-SNAPSHOT' apply(false)
19+
id 'org.spongepowered.mixin' version '0.7-SNAPSHOT' apply(false)
20+
id 'net.darkhax.curseforgegradle' version '1.1.15' apply(false)
21+
id 'com.modrinth.minotaur' version '2.8.0' apply(false)
22+
}
23+
1524
apply from: 'gradle/property_loader.gradle'
1625
apply from: 'gradle/build_number.gradle'
1726
apply from: 'gradle/git_changelog.gradle'
@@ -48,16 +57,6 @@ subprojects {
4857
name = 'Sponge / Mixin'
4958
url = 'https://repo.spongepowered.org/repository/maven-public/'
5059
}
51-
52-
maven {
53-
name = 'BlameJared Maven (CrT / Bookshelf)'
54-
url = 'https://maven.blamejared.com'
55-
}
56-
57-
maven {
58-
name = 'Mod Menu'
59-
url = 'https://maven.terraformersmc.com/releases/'
60-
}
6160
}
6261
}
6362

@@ -82,14 +81,14 @@ task postDiscord() {
8281
def embed = new Embed();
8382
def downloadSources = new StringJoiner('\n')
8483

85-
if (project(':Forge').hasProperty('curse_file_url')) {
84+
if (project(':forge').hasProperty('curse_file_url')) {
8685

87-
downloadSources.add("<:forge:916233930091401266> [Forge](${project(':Forge').findProperty('curse_file_url')})")
86+
downloadSources.add("<:forge:916233930091401266> [Forge](${project(':forge').findProperty('curse_file_url')})")
8887
}
8988

90-
if (project(':Fabric').hasProperty('curse_file_url')) {
89+
if (project(':fabric').hasProperty('curse_file_url')) {
9190

92-
downloadSources.add("<:fabric:916233929722314763> [Fabric](${project(':Fabric').findProperty('curse_file_url')})")
91+
downloadSources.add("<:fabric:916233929722314763> [Fabric](${project(':fabric').findProperty('curse_file_url')})")
9392
}
9493

9594
// Add Curseforge DL link if available.

Common/build.gradle renamed to common/build.gradle

Lines changed: 7 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,12 @@
11
plugins {
2-
id 'org.spongepowered.gradle.vanilla' version '0.2.1-SNAPSHOT'
2+
id 'org.spongepowered.gradle.vanilla'
33
}
44

55
apply from: '../gradle/property_helper.gradle'
66

7-
archivesBaseName = "${mod_name}-Common-${minecraft_version}"
7+
base {
8+
archivesName = "${mod_name}-Common-${minecraft_version}"
9+
}
810

911
minecraft {
1012
version(minecraft_version)
@@ -26,25 +28,13 @@ processResources {
2628

2729
// -- MAVEN PUBLISHING --
2830
project.publishing {
29-
31+
3032
publications {
3133

3234
mavenJava(MavenPublication) {
33-
34-
artifactId project.archivesBaseName
3535

36-
// Base mod archive.
37-
artifact jar
38-
39-
// Adds the sources as an artifact.
40-
artifact project.sourcesJar {
41-
classifier 'sources'
42-
}
43-
44-
// Adds the javadocs as an artifact.
45-
artifact project.javadocJar {
46-
classifier 'javadoc'
47-
}
36+
artifactId = base.archivesName.get()
37+
from components.java
4838
}
4939
}
5040

0 commit comments

Comments
 (0)