initial commit

This commit is contained in:
2024-12-28 09:02:28 +08:00
commit 8fcbe4511b
374 changed files with 49430 additions and 0 deletions

105
build.gradle Normal file
View File

@@ -0,0 +1,105 @@
plugins {
id 'java-library'
alias catalog.plugins.sambal
id 'maven-publish'
}
allprojects {
group = 'net.woggioni'
version = project.currentTag ?: "${getProperty('xmemcached.version')}-SNAPSHOT"
pluginManager.withPlugin('java-library') {
repositories {
mavenCentral()
}
java {
withSourcesJar()
modularity.inferModulePath = true
toolchain {
languageVersion = JavaLanguageVersion.of(21)
}
}
test {
useJUnitPlatform()
systemProperty('junit.jupiter.execution.parallel.enabled', 'true')
systemProperty('junit.jupiter.execution.parallel.mode.classes.default', 'concurrent')
systemProperty('junit.jupiter.execution.parallel.mode.default = concurrent', 'concurrent')
// systemProperty('test.memcached.host', 'localhost')
// systemProperty('test.memcached.port', '1211')
// systemProperty('test.memcached.servers', 'localhost:1211')
filter {
excludeTestsMatching "*IT"
}
}
}
pluginManager.withPlugin(catalog.plugins.lombok.get().pluginId) {
lombok {
version = catalog.versions.lombok.get()
}
}
pluginManager.withPlugin('maven-publish') {
pluginManager.withPlugin('java-library') {
java {
// withJavadocJar()
withSourcesJar()
}
}
publishing {
repositories {
maven {
name = "Gitea"
url = uri(getProperty('gitea.maven.url'))
credentials(HttpHeaderCredentials) {
name = "Authorization"
value = "token ${System.getenv()["PUBLISHER_TOKEN"]}"
}
authentication {
header(HttpHeaderAuthentication)
}
}
}
publications {
maven(MavenPublication) {
from(components["java"])
}
}
}
}
}
dependencies {
implementation catalog.slf4j.api
// https://mvnrepository.com/artifact/org.springframework/spring-core
compileOnly group: 'org.springframework', name: 'spring-context', version: getProperty('spring.version')
// https://mvnrepository.com/artifact/org.springframework/spring-core
compileOnly group: 'org.springframework', name: 'spring-beans', version: getProperty('spring.version')
// https://mvnrepository.com/artifact/org.easymock/easymock
testImplementation group: 'org.easymock', name: 'easymock', version: getProperty('easymock.version')
testImplementation catalog.junit.jupiter.api
testRuntimeOnly catalog.junit.jupiter.engine
// https://mvnrepository.com/artifact/org.springframework/spring-core
testImplementation group: 'org.springframework', name: 'spring-context', version: getProperty('spring.version')
// https://mvnrepository.com/artifact/org.springframework/spring-core
testImplementation group: 'org.springframework', name: 'spring-beans', version: getProperty('spring.version')
// testImplementation platform(group: "org.testcontainers", name: "testcontainers-bom", version: "1.20.4")
// testImplementation group: "org.testcontainers", name: 'testcontainers'
// testImplementation group: 'org.testcontainers', name: 'junit-jupiter'
}