-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
2ceb51f
commit 37f1d98
Showing
2 changed files
with
111 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,111 @@ | ||
plugins { | ||
id 'io.papermc.paperweight.userdev' version '1.5.11' | ||
id 'com.github.johnrengelman.shadow' version '8.1.1' | ||
id 'java-library' | ||
} | ||
|
||
allprojects { | ||
apply plugin: 'java' | ||
apply plugin: 'maven-publish' | ||
apply plugin: 'com.github.johnrengelman.shadow' | ||
|
||
group = 'com.github.Outspending' | ||
version = '0.0.1' | ||
|
||
sourceCompatibility = 17 | ||
targetCompatibility = 17 | ||
|
||
// The file for publication. | ||
def publishFile = layout.buildDirectory.file("libs/${project.name}-${project.version}.jar") | ||
|
||
// publish NMS apis | ||
// this is required because consumers require getting the POM | ||
// files from this project's dependencies, even if they're completely | ||
// shaded and included in this file. | ||
// | ||
// not optimal because this leads to more network calls when downloading | ||
// the api for the first time. | ||
publishing { | ||
publications { | ||
create('maven', MavenPublication) { | ||
groupId = 'com.github.Outspending' | ||
artifactId = project.name | ||
|
||
artifact publishFile | ||
from components.java | ||
} | ||
} | ||
} | ||
|
||
tasks.withType(JavaCompile) { | ||
options.encoding = 'UTF-8' | ||
} | ||
|
||
} | ||
|
||
subprojects { | ||
|
||
repositories { | ||
mavenCentral() | ||
maven { | ||
name = "papermc-repo" | ||
url = "https://repo.papermc.io/repository/maven-public/" | ||
} | ||
maven { | ||
name = "sonatype" | ||
url = "https://oss.sonatype.org/content/groups/public/" | ||
} | ||
} | ||
|
||
dependencies { | ||
compileOnly 'org.projectlombok:lombok:1.18.30' | ||
annotationProcessor 'org.projectlombok:lombok:1.18.30' | ||
} | ||
|
||
} | ||
|
||
repositories { | ||
mavenCentral() | ||
maven { | ||
name = "papermc-repo" | ||
url = "https://repo.papermc.io/repository/maven-public/" | ||
} | ||
maven { | ||
name = "sonatype" | ||
url = "https://oss.sonatype.org/content/groups/public/" | ||
} | ||
} | ||
|
||
|
||
|
||
// NMS Versions | ||
def biomesNMSVersions = ["1.19_R2", "1.19_R3", "1.20_R1", "1.20_R2", "1.20_R3"] | ||
|
||
dependencies { | ||
paperweight.paperDevBundle("1.20-R0.1-SNAPSHOT") | ||
|
||
implementation project(':NMS:Wrapper') | ||
biomesNMSVersions.each { version -> | ||
implementation project(":NMS:${version}") | ||
} | ||
|
||
compileOnly 'org.projectlombok:lombok:1.18.30' | ||
annotationProcessor 'org.projectlombok:lombok:1.18.30' | ||
|
||
} | ||
|
||
publishMavenPublicationToMavenLocal { | ||
// Throws an error if we don't explicitly say we're using the output | ||
// of reobfJar in the final build. | ||
dependsOn(reobfJar) | ||
} | ||
|
||
reobfJar { | ||
// Make sure it's the correct name for when it's inserted into the publication | ||
outputJar.set(buildFile) | ||
} | ||
|
||
wrapper { | ||
gradleVersion = '8.1.1' | ||
distributionType = Wrapper.DistributionType.ALL | ||
} |
This file was deleted.
Oops, something went wrong.