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
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -122,3 +122,4 @@ run/
/api/target/
/backend-api/target/
/.fastRequest/
/deploy/
87 changes: 65 additions & 22 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -5,22 +5,46 @@ buildscript {
}
}
dependencies {
classpath("gradle.plugin.com.github.johnrengelman:shadow:7.1.2")
classpath("com.gradleup.shadow:shadow-gradle-plugin:8.3.6") // for shadowing
classpath("io.freefair.gradle:lombok-plugin:8.6")
}
}

allprojects {
apply plugin: "java"
apply plugin: "com.gradleup.shadow"
apply plugin: "io.freefair.lombok"
apply plugin: "maven-publish"

version = rootProject.properties["version"]
group = rootProject.properties["group"]

java {
sourceCompatibility = JavaVersion.VERSION_11
targetCompatibility = JavaVersion.VERSION_11
}

artifacts {
archives shadowJar
}

repositories {
// Maven Defaults
mavenCentral()
mavenLocal()
maven { url "https://mvnrepository.com/artifact" }

// JitPack
maven { url "https://jitpack.io" }

// Local libs folder as a flat directory repository
flatDir {
dirs "${rootDir}/libs"
}
}
}

subprojects {
apply plugin: "java"
apply plugin: "com.github.johnrengelman.shadow"
apply plugin: "io.freefair.lombok"
apply plugin: "maven-publish"

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

ext {
Expand All @@ -33,9 +57,6 @@ subprojects {
targetCompatibility = JavaVersion.VERSION_11

repositories {
mavenCentral()
mavenLocal()

// Spigot / Bukkit
maven {
url "https://hub.spigotmc.org/nexus/content/repositories/snapshots"
Expand All @@ -55,9 +76,6 @@ subprojects {
maven { url "https://maven.fabricmc.net" }
maven { url "https://libraries.minecraft.net" }

// JitPack
maven { url "https://jitpack.io" }
maven { url "https://mvnrepository.com/artifact" }
// OpenCollab
maven {
name "opencollabRepositoryMavenSnapshots"
Expand All @@ -72,11 +90,6 @@ subprojects {
maven { url "https://repo.extendedclip.com/content/repositories/placeholderapi" }
}

java {
sourceCompatibility = JavaVersion.VERSION_11
targetCompatibility = JavaVersion.VERSION_11
}

processResources {
// Debugging: Print values
doFirst {
Expand All @@ -92,7 +105,12 @@ subprojects {
expand (
"name": rootProject.name.toString(),
"version": rootProject.version.toString(),
"main": project.ext.pluginMain.toString(),
)
}
filesMatching("**/velocity-plugin.json") {
expand (
"name": rootProject.name.toString(),
"version": rootProject.version.toString(),
)
}
filesMatching("**/streamline.properties") {
Expand Down Expand Up @@ -124,10 +142,6 @@ subprojects {
// minimize()
}

artifacts {
archives shadowJar
}

tasks.register('deploy', Copy) {
// Define the deployment directory
def deployDir = file(System.getenv("DEPLOY_DIR") ?: "$rootDir/deploy")
Expand Down Expand Up @@ -168,6 +182,35 @@ subprojects {
}
}

//tasks.register("clearDeploys", Delete) {
// // Define the deployment directory
// def deployDir = file(System.getenv("DEPLOY_DIR") ?: "$rootDir/deploy")
//
// deployDir.mkdirs()
// File[] files = deployDir.listFiles()
// if (files != null) {
// files.each { file ->
// if (file.isFile()) {
// file.delete()
// }
// }
// }
//}

//clean.finalizedBy(clearDeploys)
//tasks.named('clearDeploys').configure {
// dependsOn 'clean'
//}

//clearDeploys.finalizedBy(build)
//tasks.named("build") {
// doFirst {
// tasks.named('clean') {
// it.
// }
// }
//}

wrapper {
gradleVersion = "8.9"
distributionType = Wrapper.DistributionType.ALL
Expand Down
5 changes: 2 additions & 3 deletions bungee/build.gradle
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
dependencies {
// Platform.
compileOnly 'net.md-5:bungeecord-api:1.20-R0.3-SNAPSHOT'
compileOnly 'net.md-5:bungeecord-parent:1.20-R0.3-SNAPSHOT'
// Platform
annotationProcessor(compileOnly('net.md-5:bungeecord-api:1.21-R0.1-SNAPSHOT'))

// Defaults.
compileOnly(files(FILES))
Expand Down
15 changes: 13 additions & 2 deletions bungee/src/main/java/net/streamline/platform/BasePlugin.java
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@
import java.util.*;
import java.util.concurrent.ConcurrentSkipListMap;
import java.util.concurrent.ConcurrentSkipListSet;
import java.util.logging.Logger;

public abstract class BasePlugin extends Plugin implements ISingularityExtension {
@Getter
Expand Down Expand Up @@ -120,8 +121,6 @@ public void setupProperties() {

@Override
public void onEnable() {
getLogger().addHandler(new CosmicLogHandler());

userManager = new UserManager();
messenger = new Messenger();
consoleHolder = new ConsoleHolder();
Expand Down Expand Up @@ -156,6 +155,8 @@ public void onDisable() {
UserUtils.syncAllUsers();
UuidManager.getUuids().forEach(UuidInfo::save);

getProxy().unregisterChannel(SLAPI.getApiChannel());

this.disable();
fireStopEvent();

Expand Down Expand Up @@ -349,4 +350,14 @@ public static ConcurrentSkipListMap<String, ProxiedPlayer> getPlayersByUUID() {
}
return map;
}

@Override
public Logger getLoggerLogger() {
return getLogger();
}

@Override
public org.slf4j.Logger getSLFLogger() {
return null;
}
}
2 changes: 1 addition & 1 deletion bungee/src/main/resources/plugin.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: '${name}'
version: '${version}'
main: 'net.streamline.base.StreamlineBungee'
authors:
- MrDrakify
- Drak
website: https://github.com/Streamline-Essentials
description: True potential is here. A Proxy and Spigot plugin that opens up endless cross-platform possibilities.
depend:
Expand Down
2 changes: 2 additions & 0 deletions dependencies.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,14 @@ ext {
"com.github.Server-Utilities:TheBase:master-SNAPSHOT",
"org.pf4j:pf4j:3.10.0",
"commons-codec:commons-codec:1.5",
"ch.qos.logback:logback-classic:1.5.6",
]
SHADOW = [
"com.github.ben-manes.caffeine:caffeine:3.1.8",
"com.github.Server-Utilities:TheBase:master-SNAPSHOT",
"org.pf4j:pf4j:3.10.0",
"commons-codec:commons-codec:1.5",
"ch.qos.logback:logback-classic:1.5.6",
]
ANNO = [
"com.github.ben-manes.caffeine:caffeine:3.1.8",
Expand Down
44 changes: 0 additions & 44 deletions folia/build.gradle

This file was deleted.

45 changes: 0 additions & 45 deletions folia/src/main/java/net/streamline/base/Streamline.java

This file was deleted.

48 changes: 0 additions & 48 deletions folia/src/main/java/net/streamline/base/TenSecondTimer.java

This file was deleted.

Loading