Skip to content

Commit

Permalink
放弃多模块了,类关系有点难处理
Browse files Browse the repository at this point in the history
  • Loading branch information
YufiriaMazenta committed Feb 17, 2024
1 parent 76796a9 commit 7735f28
Show file tree
Hide file tree
Showing 33 changed files with 41 additions and 118 deletions.
Empty file removed api/build.gradle.kts
Empty file.
87 changes: 37 additions & 50 deletions build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
import java.text.SimpleDateFormat

version = "2.0.0-dev1"
group = "com.github.yufiria.craftorithm"
group = "com.github.yufiria"
val crypticlibVersion = "0.16.0"
java.sourceCompatibility = JavaVersion.VERSION_1_8
java.targetCompatibility = JavaVersion.VERSION_1_8
var repositoryUrl = "http://repo.crypticlib.com:8081/repository/"
Expand All @@ -17,16 +20,36 @@ plugins {

repositories {
mavenLocal()
maven("https://oss.sonatype.org/content/groups/public/")
maven("http://repo.crypticlib.com:8081/repository/maven-public/") {
isAllowInsecureProtocol = true
}
maven("https://jitpack.io")
maven("https://repo.rosewooddev.io/repository/public/")
maven("https://repo.extendedclip.com/content/repositories/placeholderapi/")
maven("https://repo.maven.apache.org/maven2/")
maven("https://mvn.lumine.io/repository/maven-public/")
maven("https://r.irepo.space/maven/")
maven("https://repo.papermc.io/repository/maven-public/")
maven("https://nexus.phoenixdevt.fr/repository/maven-public/")
mavenCentral()
}

dependencies {
implementation("com.crypticlib:CrypticLib:0.16.0")
implementation(project(":api"))
implementation(project(":plugin"))
implementation("com.crypticlib:CrypticLib:$crypticlibVersion")
compileOnly("org.jetbrains:annotations:24.0.1")
compileOnly("pers.neige.neigeitems:NeigeItems:1.15.113")
compileOnly("net.kyori:adventure-api:4.14.0")
compileOnly("com.github.MilkBowl:VaultAPI:1.7")
compileOnly("org.black_ixx:playerpoints:3.2.5")
compileOnly("net.luckperms:api:5.4")
compileOnly("me.clip:placeholderapi:2.11.1")
compileOnly("com.github.LoneDev6:API-ItemsAdder:3.5.0b")
compileOnly("com.github.oraxen:oraxen:1.160.0")
compileOnly("io.lumine:Mythic-Dist:5.3.5")
compileOnly("io.lumine:MythicLib-dist:1.6.2-SNAPSHOT")
compileOnly("net.Indyuce:MMOItems-API:6.9.5-SNAPSHOT")
// compileOnly("io.papermc.paper:paper-api:1.20.4")
}

tasks {
Expand All @@ -40,6 +63,16 @@ tasks {
archiveFileName.set("Craftorithm-$version.jar")
relocate("crypticlib", "com.github.yufiria.craftorithm.crypticlib")
}
val props = HashMap<String, String>()
props["version"] = version.toString() + "-" + SimpleDateFormat("yyyyMMdd").format(System.currentTimeMillis())
processResources {
filesMatching("plugin.yml") {
expand(props)
}
filesMatching("config.yml") {
expand(props)
}
}
}

publishing {
Expand All @@ -59,50 +92,4 @@ publishing {
}
}
}
}

subprojects {
apply(plugin = "java")
apply(plugin = "maven-publish")

repositories {
mavenLocal()
maven("https://hub.spigotmc.org/nexus/content/repositories/snapshots/")
mavenCentral()
}

dependencies {
compileOnly("org.jetbrains:annotations:24.0.1")
compileOnly("org.spigotmc:spigot-api:1.20.4-R0.1-SNAPSHOT")

}

java.sourceCompatibility = JavaVersion.VERSION_1_8
java.targetCompatibility = JavaVersion.VERSION_1_8
version = rootProject.version

tasks {
compileJava {
options.encoding = "UTF-8"
}
}

publishing {
publishing {
publications.create<MavenPublication>("maven") {
from(components["java"])
groupId = rootProject.group as String?
}
repositories {
maven {
url = uri(repositoryUrl)
isAllowInsecureProtocol = true
credentials {
username = project.findProperty("maven_username").toString()
password = project.findProperty("maven_password").toString()
}
}
}
}
}
}
55 changes: 0 additions & 55 deletions plugin/build.gradle.kts

This file was deleted.

4 changes: 1 addition & 3 deletions settings.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
rootProject.name = "Craftorithm"
include("api")
include("plugin")
rootProject.name = "Craftorithm"
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import crypticlib.config.ConfigWrapper;
import crypticlib.util.ItemUtil;
import crypticlib.util.MaterialUtil;
import org.bukkit.Bukkit;
import org.bukkit.Material;
import org.bukkit.NamespacedKey;
import org.bukkit.configuration.ConfigurationSection;
Expand All @@ -14,10 +15,7 @@
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;

import java.util.LinkedHashMap;
import java.util.Map;
import java.util.Set;
import java.util.UUID;
import java.util.*;
import java.util.concurrent.ConcurrentHashMap;

public enum ItemManager {
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,15 +1,10 @@
name: Craftorithm
version: '${version}'
description: Craft recipes management system
main: com.github.yufiria.craftorithm.Craftorithm
main: com.github.yufiriamazenta.craftorithm.Craftorithm
api-version: 1.13
load: POSTWORLD
softdepend: [ Vault, LuckPerms, PlayerPoints, PlaceholderAPI, ItemsAdder, Oraxen, MythicMobs, NeigeItems, MMOItems ]
authors: [ YufiriaMazenta ]
folia-supported: true
website: https://github.com/YufiriaMazenta/Craftorithm
permissions:
craftorithm.command:
description: Plugin command main permissions
craftorithm.edit_recipe:
default: op

0 comments on commit 7735f28

Please sign in to comment.