Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions api/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -25,4 +25,8 @@ dependencies {

compileJava {
dependsOn(":StreamlineCore-Singularity:jar")
}

delombok {
dependsOn(":StreamlineCore-Singularity:jar")
}
6 changes: 5 additions & 1 deletion backend-api/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,10 @@ dependencies {
compileOnly(files(FILES))
}

tasks.named("compileJava").configure {
compileJava {
dependsOn(":StreamlineCore-API:jar")
}

delombok {
dependsOn(":StreamlineCore-API:jar")
}
63 changes: 13 additions & 50 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,9 @@ buildscript {
}
}

plugins {
id "java"
id "com.github.johnrengelman.shadow" version "7.1.2"
id "maven-publish" // for jitpack.io
allprojects {
version = rootProject.properties["version"]
group = rootProject.properties["group"]
}

subprojects {
Expand All @@ -24,11 +23,8 @@ subprojects {

apply from: rootDir.toString() + "/dependencies.gradle"

group = properties["group"]
version = properties["version"]

ext {
pluginMain = properties["plugin.main"] == "default" ?
pluginMain = rootProject.properties["plugin.main"] == "default" ?
project.group.toString() + "." + project.name.toString().toLowerCase() + "." + project.name.toString() :
properties["plugin.main"]
}
Expand Down Expand Up @@ -147,57 +143,24 @@ subprojects {
shadowJar.finalizedBy(deploy)

tasks.named('deploy').configure {
dependsOn 'shadowJar', 'sourcesJar', /*'javadocJar',*/ 'jar'
dependsOn 'shadowJar', 'sourcesJar', 'javadocJar', 'jar'
}

java {
withSourcesJar()
withJavadocJar()
}

publishing {
publications {
maven(MavenPublication) {
groupId project.group
artifactId project.name
version project.version
from components.java
}
}
}

java {
withSourcesJar()
// withJavadocJar()
}
}

tasks.register('deploy', Copy) {
// Define the deployment directory
def deployDir = file(System.getenv("DEPLOY_DIR") ?: "$rootDir/deploy")

// Ensure the deployment directory exists
doFirst {
println "Deploying to: $deployDir"
deployDir.mkdirs()
println "Generated JAR file: ${shadowJar.archiveFile}"
}

// Copy the shadowJar output
from shadowJar.archiveFile
into deployDir
}

// Ensure that the deploy task runs after the shadowJar task
shadowJar.finalizedBy(deploy)

tasks.named('deploy').configure {
dependsOn 'shadowJar', 'sourcesJar', /*'javadocJar',*/ 'jar'
}

publishing {
publications {
maven(MavenPublication) {
from components.java
}
}
}

java {
withSourcesJar()
// withJavadocJar()
}

wrapper {
Expand Down
6 changes: 5 additions & 1 deletion bungee/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,10 @@ dependencies {
compileOnly project(path: ':StreamlineCore-Singularity')
}

tasks.named("compileJava").configure {
compileJava {
dependsOn(":StreamlineCore-API:jar")
}

delombok {
dependsOn(":StreamlineCore-API:jar")
}
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ org.gradle.vfs.watch = false

# Other properties
name = StreamlineCore
group = com.github.streamline-essentials
group = com.github.Streamline-Essentials.StreamlineCore
version = 2.5.0.0

base-version = c8388399
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -94,12 +94,6 @@ public UpdateFunction defaultParser(String identifier) {
* Adjusts the given time in milliseconds, ensuring that the `millis + millisBetweenUpdates - adjusted amount`
* is always less than @link{System#currentTimeMillis()} when the method is called @link{millisBetweenUpdates}
* after the last update.
* For example,
* given getAdjustedMillis(date.getTime()) + getMillisBetweenUpdates() < System.currentTimeMillis(),
* if date.getTime() = 1000, getMillisBetweenUpdates() = 1000, System.currentTimeMillis() = 2000,
* it will return 1000 - 1 = 999
* if date.getTime() = 1010, getMillisBetweenUpdates() = 1000, System.currentTimeMillis() = 2000,
* it will return 1001 - 1 = 1000
*
* @param millis The time in milliseconds to adjust.
* @return The adjusted time in milliseconds.
Expand Down
6 changes: 5 additions & 1 deletion spigot/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,10 @@ dependencies {
compileOnly project(path: ":StreamlineCore-Singularity")
}

tasks.named("compileJava").configure {
compileJava {
dependsOn(":StreamlineCore-BAPI:jar")
}

delombok {
dependsOn(":StreamlineCore-BAPI:jar")
}
6 changes: 5 additions & 1 deletion velocity/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,10 @@ dependencies {
compileOnly project(path: ':StreamlineCore-Singularity')
}

tasks.named("compileJava").configure {
compileJava {
dependsOn(":StreamlineCore-API:jar")
}

delombok {
dependsOn(":StreamlineCore-API:jar")
}
Loading