initial commit
This commit is contained in:
commit
574098a06a
21 changed files with 1924 additions and 0 deletions
54
build.gradle
Normal file
54
build.gradle
Normal file
|
|
@ -0,0 +1,54 @@
|
|||
plugins {
|
||||
id 'java'
|
||||
id 'org.jetbrains.gradle.plugin.idea-ext' version '1.3'
|
||||
id("xyz.jpenilla.run-velocity") version "2.3.1"
|
||||
}
|
||||
|
||||
group = 'com.uravgcode'
|
||||
version = '1.0'
|
||||
|
||||
repositories {
|
||||
mavenCentral()
|
||||
maven {
|
||||
name = "papermc-repo"
|
||||
url = "https://repo.papermc.io/repository/maven-public/"
|
||||
}
|
||||
}
|
||||
|
||||
dependencies {
|
||||
compileOnly("com.velocitypowered:velocity-api:3.4.0-SNAPSHOT")
|
||||
annotationProcessor("com.velocitypowered:velocity-api:3.4.0-SNAPSHOT")
|
||||
|
||||
implementation("com.google.code.gson:gson:2.13.1")
|
||||
}
|
||||
|
||||
tasks {
|
||||
runVelocity {
|
||||
velocityVersion("3.4.0-SNAPSHOT")
|
||||
}
|
||||
}
|
||||
|
||||
def targetJavaVersion = 21
|
||||
java {
|
||||
toolchain.languageVersion = JavaLanguageVersion.of(targetJavaVersion)
|
||||
}
|
||||
|
||||
tasks.withType(JavaCompile).configureEach {
|
||||
options.encoding = 'UTF-8'
|
||||
options.release.set(targetJavaVersion)
|
||||
}
|
||||
|
||||
def templateSource = file('src/main/templates')
|
||||
def templateDest = layout.buildDirectory.dir('generated/sources/templates')
|
||||
def generateTemplates = tasks.register('generateTemplates', Copy) { task ->
|
||||
def props = ['version': project.version]
|
||||
task.inputs.properties props
|
||||
|
||||
task.from templateSource
|
||||
task.into templateDest
|
||||
task.expand props
|
||||
}
|
||||
|
||||
sourceSets.main.java.srcDir(generateTemplates.map { it.outputs })
|
||||
|
||||
project.idea.project.settings.taskTriggers.afterSync generateTemplates
|
||||
Loading…
Add table
Add a link
Reference in a new issue