chore: convert some plugins to gradle
This commit is contained in:
2
.gitignore
vendored
2
.gitignore
vendored
@@ -24,7 +24,7 @@ gradle-app.setting
|
||||
.DS_Store
|
||||
|
||||
|
||||
|
||||
*-1.0-SNAPSHOT.jar
|
||||
|
||||
|
||||
.vscode/*
|
||||
|
||||
@@ -9,8 +9,8 @@ description = "dailyquests"
|
||||
|
||||
|
||||
dependencies {
|
||||
implementation(files("/Users/janik/Desktop/MCPlugins/craftbukkit-1.21.1.jar"))
|
||||
implementation(files("/Users/janik/Desktop/helper-1.0-SNAPSHOT.jar"))
|
||||
implementation(files("../craftbukkit.jar"))
|
||||
implementation(files("../helper-1.0-SNAPSHOT.jar"))
|
||||
paperweight.paperDevBundle("1.21.4-R0.1-SNAPSHOT")
|
||||
}
|
||||
|
||||
|
||||
@@ -9,8 +9,8 @@ description = "environmentex"
|
||||
|
||||
|
||||
dependencies {
|
||||
implementation(files("/Users/janik/Desktop/MCPlugins/craftbukkit.jar"))
|
||||
implementation(files("/Users/janik/Desktop/helper-1.0-SNAPSHOT.jar"))
|
||||
implementation(files("../craftbukkit.jar"))
|
||||
implementation(files("../helper-1.0-SNAPSHOT.jar"))
|
||||
paperweight.paperDevBundle("1.21.4-R0.1-SNAPSHOT")
|
||||
}
|
||||
|
||||
|
||||
48
helper/build.gradle.kts
Executable file
48
helper/build.gradle.kts
Executable file
@@ -0,0 +1,48 @@
|
||||
plugins {
|
||||
`java-library`
|
||||
id("io.papermc.paperweight.userdev") version "2.0.0-beta.14"
|
||||
id("xyz.jpenilla.run-paper") version "2.3.1" // Adds runServer and runMojangMappedServer tasks for testing
|
||||
}
|
||||
group = "de.hessj.helper"
|
||||
version = "1.0-SNAPSHOT"
|
||||
description = "helper"
|
||||
|
||||
tasks.withType<Jar> {
|
||||
destinationDirectory.set(file("../"))
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation(files("../craftbukkit.jar"))
|
||||
paperweight.paperDevBundle("1.21.4-R0.1-SNAPSHOT")
|
||||
}
|
||||
|
||||
tasks {
|
||||
// Configure reobfJar to run when invoking the build task
|
||||
assemble {
|
||||
dependsOn(reobfJar)
|
||||
}
|
||||
|
||||
compileJava {
|
||||
options.encoding = Charsets.UTF_8.name() // We want UTF-8 for everything
|
||||
|
||||
// Set the release flag. This configures what version bytecode the compiler will emit, as well as what JDK APIs are usable.
|
||||
// See https://openjdk.java.net/jeps/247 for more information.
|
||||
options.release.set(21)
|
||||
}
|
||||
javadoc {
|
||||
options.encoding = Charsets.UTF_8.name() // We want UTF-8 for everything
|
||||
}
|
||||
processResources {
|
||||
filteringCharset = Charsets.UTF_8.name() // We want UTF-8 for everything
|
||||
val props = mapOf(
|
||||
"name" to project.name,
|
||||
"version" to project.version,
|
||||
"description" to project.description,
|
||||
"apiVersion" to "1.21"
|
||||
)
|
||||
inputs.properties(props)
|
||||
filesMatching("plugin.yml") {
|
||||
expand(props)
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,53 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>de.hessj.helper</groupId>
|
||||
<artifactId>helper</artifactId>
|
||||
<version>1.0-SNAPSHOT</version>
|
||||
<packaging>jar</packaging>
|
||||
<properties>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
<maven.compiler.source>23</maven.compiler.source>
|
||||
<maven.compiler.target>23</maven.compiler.target>
|
||||
</properties>
|
||||
<repositories>
|
||||
<repository>
|
||||
<id>papermc</id>
|
||||
<url>https://repo.papermc.io/repository/maven-public/</url>
|
||||
</repository>
|
||||
</repositories>
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>io.papermc.paper</groupId>
|
||||
<artifactId>paper-api</artifactId>
|
||||
<version>1.21.4-R0.1-SNAPSHOT</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.bukkit</groupId>
|
||||
<artifactId>mc-api</artifactId>
|
||||
<version>1.0</version>
|
||||
<scope>system</scope>
|
||||
<systemPath>/Users/janik/Desktop/MCPlugins/craftbukkit.jar</systemPath>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
<build>
|
||||
<sourceDirectory>${project.basedir}/src/main/java</sourceDirectory>
|
||||
<resources>
|
||||
<resource>
|
||||
<directory>${project.basedir}/src/main/resources</directory>
|
||||
</resource>
|
||||
</resources>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-jar-plugin</artifactId>
|
||||
<version>2.3.1</version>
|
||||
<configuration>
|
||||
<outputDirectory>/Users/janik/Desktop</outputDirectory>
|
||||
</configuration>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
</project>
|
||||
5
helper/settings.gradle.kts
Executable file
5
helper/settings.gradle.kts
Executable file
@@ -0,0 +1,5 @@
|
||||
plugins {
|
||||
id("org.gradle.toolchains.foojay-resolver-convention") version "0.9.0"
|
||||
}
|
||||
|
||||
rootProject.name = "helper"
|
||||
Reference in New Issue
Block a user