Skip to content

Commit

Permalink
Some changes
Browse files Browse the repository at this point in the history
  • Loading branch information
PyCMC committed Sep 20, 2024
1 parent e93592e commit 6562def
Show file tree
Hide file tree
Showing 3 changed files with 39 additions and 24 deletions.
11 changes: 0 additions & 11 deletions .run/PNX.run.xml

This file was deleted.

50 changes: 37 additions & 13 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,16 @@ repositories {
maven("https://jitpack.io")
maven("https://repo.opencollab.dev/maven-releases/")
maven("https://repo.opencollab.dev/maven-snapshots/")

maven {
url = uri("http://10.10.10.96:3000/api/packages/server/maven") // Replace with your Gitea URL
isAllowInsecureProtocol = true

credentials {
username = findProperty("giteaUsername") as String? ?: System.getenv("GITEA_USERNAME")
password = findProperty("giteaPassword") as String? ?: System.getenv("GITEA_PASSWORD")
}
}
}

dependencies {
Expand Down Expand Up @@ -69,14 +79,14 @@ dependencies {

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

//Automatically download dependencies source code
idea {
module {
isDownloadSources = true
isDownloadJavadoc = false
//isDownloadJavadoc = false
}
}

Expand All @@ -92,8 +102,8 @@ tasks.register<DefaultTask>("buildFast") {
dependsOn(tasks.build)
group = "alpha build"
tasks["delombok"].enabled = false
tasks["javadoc"].enabled = false
tasks["javadocJar"].enabled = false
//tasks["javadoc"].enabled = false
//tasks["javadocJar"].enabled = false
tasks["sourcesJar"].enabled = false
tasks["copyDependencies"].enabled = false
tasks["shadowJar"].enabled = false
Expand All @@ -108,8 +118,8 @@ tasks.register<DefaultTask>("buildSkipChores") {
dependsOn(tasks.build)
group = "alpha build"
tasks["delombok"].enabled = false
tasks["javadoc"].enabled = false
tasks["javadocJar"].enabled = false
//tasks["javadoc"].enabled = false
//tasks["javadocJar"].enabled = false
tasks["sourcesJar"].enabled = false
tasks["compileTestJava"].enabled = false
tasks["processTestResources"].enabled = false
Expand All @@ -122,8 +132,8 @@ tasks.register<DefaultTask>("buildForGithubAction") {
dependsOn(tasks.build)
group = "build"
tasks["delombok"].enabled = false
tasks["javadoc"].enabled = false
tasks["javadocJar"].enabled = false
//tasks["javadoc"].enabled = false
//tasks["javadocJar"].enabled = false
}

tasks.build {
Expand Down Expand Up @@ -197,29 +207,43 @@ tasks.register<Copy>("copyDependencies") {
into(layout.buildDirectory.dir("libs"))
}

tasks.javadoc {
tasks.javadoc {}
/*
options.encoding = StandardCharsets.UTF_8.name()
includes.add("**/**.java")
includes.add("** / **.java")
val javadocOptions = options as CoreJavadocOptions
javadocOptions.addStringOption(
"source",
java.sourceCompatibility.toString()
)
// Suppress some meaningless warnings
javadocOptions.addStringOption("Xdoclint:none", "-quiet")
}
}
*/

publishing {
publications.create<MavenPublication>("maven") {
from(components["java"])
pom {
repositories {
mavenLocal()
/*mavenLocal()
mavenCentral()
maven("https://repo.maven.apache.org/maven2/")
maven("https://jitpack.io")
maven("https://repo.opencollab.dev/maven-releases/")
maven("https://repo.opencollab.dev/maven-snapshots/")
maven("https://repo.opencollab.dev/maven-snapshots/")*/
maven {
url = uri("http://10.10.10.96:3000/api/packages/server/maven") // Replace with your Gitea URL
isAllowInsecureProtocol = true

credentials {
username = findProperty("giteaUsername") as String? ?: System.getenv("GITEA_USERNAME")
password = findProperty("giteaPassword") as String? ?: System.getenv("GITEA_PASSWORD")
}
}

}
}
}
Expand Down
2 changes: 2 additions & 0 deletions src/main/java/pycmc/pnxcustom/TranslationProvider.java
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@
import cn.nukkit.Player;

public abstract class TranslationProvider {
@Deprecated
public abstract String translate(String lang, String key);
@Deprecated
public abstract String translate(String lang, String key, String... params);

public abstract String translate(Player p, String key);
Expand Down

0 comments on commit 6562def

Please sign in to comment.