Skip to content

Commit

Permalink
update buildscripts
Browse files Browse the repository at this point in the history
  • Loading branch information
samolego committed Jun 10, 2021
1 parent b183bbb commit 484e883
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 14 deletions.
18 changes: 9 additions & 9 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -54,18 +54,18 @@ allprojects {
}
}

tasks.withType(JavaCompile) {
options.encoding = "UTF-8"
tasks.withType(JavaCompile).configureEach {
// ensure that the encoding is set to UTF-8, no matter what the system default is
// this fixes some edge cases with special characters not displaying correctly
// see http://yodaconditions.net/blog/fix-for-java-file-encoding-problems-with-gradle.html
// If Javadoc is generated, this must be specified in that task too.
it.options.encoding = "UTF-8"

// The Minecraft launcher currently installs Java 8 for users, so your mod probably wants to target Java 8 too
// JDK 9 introduced a new way of specifying this that will make sure no newer classes or methods are used.
// We'll use that if it's available, but otherwise we'll use the older option.
def targetVersion = 8
if (JavaVersion.current().isJava9Compatible()) {
options.release = targetVersion
}
// Minecraft 1.17 (21w19a) upwards uses Java 16.
it.options.release = 16
}


java {
withSourcesJar()
}
Expand Down
2 changes: 1 addition & 1 deletion fabric/build.gradle
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import com.modrinth.minotaur.TaskModrinthUpload

plugins {
id "com.github.johnrengelman.shadow" version "5.0.0"
id "com.github.johnrengelman.shadow" version "5.2.0"
id 'com.matthewprenger.cursegradle'
id "com.modrinth.minotaur"
// Dokka docs
Expand Down
2 changes: 1 addition & 1 deletion forge/build.gradle
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import com.modrinth.minotaur.TaskModrinthUpload

plugins {
id "com.github.johnrengelman.shadow" version "5.0.0"
id "com.github.johnrengelman.shadow" version "5.2.0"
id 'com.matthewprenger.cursegradle'
id "com.modrinth.minotaur"
// Dokka docs
Expand Down
5 changes: 2 additions & 3 deletions settings.gradle
Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
pluginManagement {
repositories {
maven { url "https://maven.fabricmc.net/" }
maven { url "https://maven.shedaniel.me/" }
maven { url "https://files.minecraftforge.net/maven/" }
maven { url "https://maven.architectury.dev/" }
maven { url "https://maven.minecraftforge.net/" }
gradlePluginPortal()
}
}


include("common")
include("fabric")
//include("forge")

0 comments on commit 484e883

Please sign in to comment.