1 Star 0 Fork 9

Zero/java-callgraph2

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
build.gradle 2.38 KB
一键复制 编辑 原始数据 按行查看 历史
apply plugin: 'eclipse'
apply plugin: 'java'
apply plugin: 'idea'
group 'com.github.adrninistrator'
version = "1.0.18"
def projectName = "java-callgraph2"
description = "${projectName}"
sourceCompatibility = 1.8
targetCompatibility = 1.8
def jar_output_dir = "jar_output_dir"
def defaultEncoding = 'UTF-8'
[compileJava, compileTestJava]*.options*.encoding = defaultEncoding
project.buildDir = 'build'
repositories {
mavenCentral()
}
clean {
delete 'build'
delete "${jar_output_dir}"
}
sourceSets {
main {
java {
srcDir 'src/main/java'
}
resources {
srcDir 'src/main/resources'
}
}
test {
java {
srcDir 'src/test/java'
}
resources {
srcDir 'src/test/resources'
}
}
}
// 6.7.0版本LDC.getValue()会报错,不使用
List bcel = ['org.apache.bcel:bcel:6.6.0']
List junit = ['junit:junit:4.13.2']
dependencies {
compile bcel
testImplementation junit
}
compileJava.options.compilerArgs << "-Xlint:unchecked" << "-Xlint:deprecation"
processResources {
setDuplicatesStrategy(DuplicatesStrategy.INCLUDE)
}
task createProject {
doFirst {
sourceSets*.java.srcDirs*.each { it.mkdirs() }
sourceSets*.resources.srcDirs*.each { it.mkdirs() }
}
}
// 生成可以直接执行的jar包,并拷贝相关文件
task gen_run_jar(type: Jar) {
archiveName 'run_javacg2.jar'
from(sourceSets.main.output) {
into '/'
}
doLast{
copy {
from 'build/libs/run_javacg2.jar'
into "${jar_output_dir}/jar/"
}
copy {
from 'src/main/resources/_javacg_config/'
into "${jar_output_dir}/_javacg_config/"
}
copy {
from 'run.bat'
into "${jar_output_dir}/"
}
copy {
from 'run.sh'
into "${jar_output_dir}/"
}
copy {
from configurations.runtimeClasspath
into "${jar_output_dir}/lib"
}
}
}
idea {
module {
// and some extra dirs that should be excluded by IDEA
excludeDirs += file('.idea')
excludeDirs += file('gradle')
excludeDirs += file('jar_output_dir')
excludeDirs += file('log_javacg')
}
}
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
Java
1
https://gitee.com/Amazing_Zero/java-callgraph2.git
git@gitee.com:Amazing_Zero/java-callgraph2.git
Amazing_Zero
java-callgraph2
java-callgraph2
main

搜索帮助