1 Star 0 Fork 27

marlon/iron

forked from pink0453/iron 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
build.gradle 2.29 KB
一键复制 编辑 原始数据 按行查看 历史
linchenguang 提交于 2022-06-20 20:22 . 分布式调用
allprojects {
apply plugin:'java'
repositories {
mavenLocal()
maven {
url = uri('https://maven.aliyun.com/repository/public')
}
maven {
url 'https://repo.maven.apache.org/maven2'
name 'Maven Central'
}
}
dependencies {
implementation 'io.vertx:vertx-core:4.3.1'
implementation 'io.vertx:vertx-hazelcast:4.3.1'
implementation 'cn.hutool:hutool-all:5.8.1'
implementation 'org.apache.logging.log4j:log4j-core:2.17.2'
implementation 'org.apache.logging.log4j:log4j-api:2.17.2'
implementation 'org.apache.logging.log4j:log4j-slf4j-impl:2.17.2'
implementation 'com.github.ben-manes.caffeine:caffeine:3.1.1'
implementation 'org.apache.commons:commons-lang3:3.12.0'
implementation 'org.quartz-scheduler:quartz-jobs:2.3.2'
implementation 'org.quartz-scheduler:quartz:2.3.2'
implementation 'org.freemarker:freemarker:2.3.31'
implementation 'org.projectlombok:lombok:1.18.24'
annotationProcessor 'org.projectlombok:lombok:1.18.24'
runtimeOnly files('../config')
}
tasks.withType(JavaCompile) {
options.encoding = 'UTF-8'
}
sourceSets {
main {
java {
srcDirs = ['src/main/java', 'src/gen/java']
}
}
}
copy {
from('src/main/java'){
include "**/*.ftl"
exclude "**/*.java"
}
into(compileJava.destinationDir)
setIncludeEmptyDirs(false)
}
}
def releasePathSub = java.nio.file.Path.of("../../../release/server")
def releaseLibSub = releasePathSub.resolve("libs")
// 生成的模块
List<String> subProjName = new ArrayList<>()
for (def f in subprojects){
subProjName.add(f.name + ".jar")
}
subprojects {
task copyToRelease(type: Copy) {
// 子模块jar
libsDirectory.set(releasePathSub.toFile())
// 用于排除config
ConfigurableFileTree confFileTree = fileTree("../config")
// 依赖的jar拷到libs
from configurations.implementation
exclude {it.file in confFileTree.getFiles()}
exclude(subProjName)
into releaseLibSub
configurations.implementation.canBeResolved(true)
}
build.dependsOn(copyToRelease)
}
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
Java
1
https://gitee.com/marlond/iron.git
git@gitee.com:marlond/iron.git
marlond
iron
iron
master

搜索帮助