1 Star 0 Fork 8

极速代码/Robo4J

forked from Gitee 极速下载/Robo4J 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
build.gradle 9.40 KB
一键复制 编辑 原始数据 按行查看 历史
Miro Wengner 提交于 2018-10-07 22:03 . Gradle cleanup
plugins {
id "org.flywaydb.flyway" version "4.2.0"
}
group 'com.robo4j'
apply plugin: 'java'
apply plugin: 'idea'
apply plugin: 'eclipse'
apply plugin: 'maven'
apply from: 'libraries.gradle'
allprojects {
repositories {
mavenCentral()
mavenLocal()
maven { url "https://oss.sonatype.org/content/repositories/snapshots/" }
}
sourceCompatibility = "${robo4jJavaVersion}"
}
subprojects {
apply plugin: 'java'
apply plugin: 'idea'
apply plugin: 'eclipse'
apply plugin: 'maven'
group 'com.robo4j'
version "${robo4jVersion}"
tasks.withType(Test){
testLogging {
events "started", "passed", "skipped", "failed"
}
}
}
project("robo4j-core") {
description = "Robo4J Core"
dependencies {
testCompile "junit:junit:${junitVersion}@jar"
testCompile "org.hamcrest:hamcrest-all:${hamcrestAllVersion}@jar"
}
test {
systemProperty "java.net.preferIPv4Stack", "true"
}
sourceSets {
main {
java {
srcDirs = ['src/main/java']
}
resources {
srcDirs = ['src/main/resources']
}
}
test {
java {
srcDirs = ['src/test/java']
}
resources {
srcDirs = ['src/test/resources']
}
}
}
}
project("robo4j-db-sql") {
description = "Robo4J Database SQL"
apply plugin: "org.flywaydb.flyway"
dependencies {
compile(project(":robo4j-core"))
compile "org.flywaydb:flyway-core:${flywayVersion}"
compile "org.hibernate.javax.persistence:hibernate-jpa-2.1-api:${hibernateJpaVersion}"
compile "org.postgresql:postgresql:${postgresqlVersion}"
compile "org.hibernate:hibernate-core:${hibernateVersion}"
compile "com.h2database:h2:${h2Version}"
testCompile project(':robo4j-core').sourceSets.test.output
testCompile "junit:junit:${junitVersion}@jar"
testCompile "org.hamcrest:hamcrest-all:${hamcrestAllVersion}@jar"
}
flyway {
url = 'jdbc:h2:~/data/robo4j1h2'
user = 'sa'
}
sourceSets {
main {
java {
srcDirs = ['src/main/java']
}
resources {
srcDirs = ['src/main/resources']
}
}
test {
java {
srcDirs = ['src/test/java']
}
resources {
srcDirs = ['src/test/resources']
}
}
}
}
project("robo4j-hw-lego") {
description = "Robo4J Lego Hardware"
dependencies {
compile fileTree(dir: 'libs', include: 'ev3classes-9.1.jar')
compile(project(":robo4j-math"))
testCompile "junit:junit:${junitVersion}"
}
sourceSets {
main {
java {
srcDirs = ['src/main/java', 'src/examples/java']
}
resources {
srcDirs = ['src/main/resources', 'src/examples/resources']
}
}
test {
java {
srcDirs = ['src/test/java']
}
resources {
srcDirs = ['src/test/resources']
}
}
}
}
project("robo4j-hw-rpi") {
description = "Robo4J RaspberryPi Hardware"
//create a single Jar with all dependencies
task fatJar(type: Jar) {
manifest {
attributes 'Implementation-Title': baseName,
'Implementation-Version': version
}
//baseName = project.name + '-all'
baseName = 'robo4j-hw-rpi'
from { configurations.compile.collect { it.isDirectory() ? it : zipTree(it) } }
with jar
}
dependencies {
compile "com.pi4j:pi4j-core:${pi4jVersion}"
compile(project(":robo4j-math"))
testCompile "junit:junit:${junitVersion}"
}
sourceSets {
main {
java {
srcDirs = ['src/main/java', 'src/examples/java']
}
resources {
srcDirs = ['src/main/resources', 'src/examples/resources']
}
}
test {
java {
srcDirs = ['src/test/java']
}
resources {
srcDirs = ['src/test/resources']
}
}
}
}
project("robo4j-math") {
description = "Robo4J Math"
dependencies {
testCompile "junit:junit:${junitVersion}"
}
sourceSets {
main {
java {
srcDirs = ['src/main/java']
}
resources {
srcDirs = ['src/main/resources']
}
}
test {
java {
srcDirs = ['src/test/java']
}
resources {
srcDirs = ['src/test/resources']
}
}
}
}
project("robo4j-page") {
description = "Robo4J Page"
dependencies {
testCompile "junit:junit:${junitVersion}@jar"
testCompile "org.hamcrest:hamcrest-all:${hamcrestAllVersion}@jar"
}
sourceSets {
main {
java {
srcDirs = ['src/main/java']
}
resources {
srcDirs = ['src/main/resources']
}
}
test {
java {
srcDirs = ['src/test/java']
}
resources {
srcDirs = ['src/test/resources']
}
}
}
}
project("robo4j-socket-http") {
description = "Robo4J socket http"
dependencies {
compile(project(":robo4j-core"))
testCompile "junit:junit:${junitVersion}@jar"
testCompile "org.hamcrest:hamcrest-all:${hamcrestAllVersion}@jar"
}
sourceSets {
main {
java {
srcDirs = ['src/main/java']
}
resources {
srcDirs = ['src/main/resources']
}
}
test {
java {
srcDirs = ['src/test/java']
}
resources {
srcDirs = ['src/test/resources']
}
}
}
}
project("robo4j-units-lego") {
description = "Robo4J Lego Abstractions"
//create a single Jar with all dependencies
task fatJar(type: Jar) {
manifest {
attributes 'Implementation-Title': 'robo4j-units-lego',
'Implementation-Version': version
}
baseName = 'robo4j-units-lego'
from { configurations.compile.collect { it.isDirectory() ? it : zipTree(it) } }
with jar
}
dependencies {
compile(project(":robo4j-core"))
compile(project(":robo4j-hw-lego"))
testCompile(project(":robo4j-socket-http"))
testCompile "junit:junit:${junitVersion}"
testCompile "org.hamcrest:hamcrest-all:${hamcrestAllVersion}"
}
sourceSets {
main {
java {
srcDirs = ['src/main/java', 'src/examples/java']
}
resources {
srcDirs = ['src/main/resources', 'src/examples/resources']
}
}
test {
java {
srcDirs = ['src/test/java']
}
resources {
srcDirs = ['src/test/resources']
}
}
}
}
project("robo4j-units-rpi") {
description = "Robo4J Raspberry Pi Units"
//create a single Jar with all dependencies
task fatJar(type: Jar) {
manifest {
attributes 'Implementation-Title': 'robo4j-units-rpi',
'Implementation-Version': version
}
//baseName = project.name + '-all'
baseName = 'robo4j-units-rpi'
from { configurations.compile.collect { it.isDirectory() ? it : zipTree(it) } }
with jar
}
dependencies {
compile(project(":robo4j-core"))
compile(project(":robo4j-hw-rpi"))
testCompile "junit:junit:${junitVersion}"
testCompile "org.hamcrest:hamcrest-all:${hamcrestAllVersion}"
}
sourceSets {
main {
java {
srcDirs = ['src/main/java', 'src/examples/java']
}
resources {
srcDirs = ['src/main/resources', 'src/examples/resources']
}
}
test {
java {
srcDirs = ['src/test/java']
}
resources {
srcDirs = ['src/test/resources']
}
}
}
}
project("robo4j-units-rpi-http") {
description = "Robo4J Codecs for rpi units"
dependencies {
compile(project(":robo4j-socket-http"))
compile(project(":robo4j-units-rpi"))
testCompile "junit:junit:${junitVersion}"
testCompile "org.hamcrest:hamcrest-all:${hamcrestAllVersion}"
}
sourceSets {
main {
java {
srcDirs = ['src/main/java']
}
}
test {
java {
srcDirs = ['src/test/java']
}
resources {
srcDirs = ['src/test/resources']
}
}
}
}
wrapper {
gradleVersion = "${roboGradleVersion}"
}
/* global settings */
configure(allprojects) { project ->
group = "com.robo4j"
compileJava.options*.compilerArgs = [
"-Xlint:unchecked", "-Xlint:rawtypes",
]
compileTestJava.options*.compilerArgs = [
"-Xlint:deprecation", "-Xlint:unchecked", "-Xlint:rawtypes",
]
}
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
Java
1
https://gitee.com/andy521/Robo4J.git
git@gitee.com:andy521/Robo4J.git
andy521
Robo4J
Robo4J
master

搜索帮助

0d507c66 1850385 C8b1a773 1850385