Select Git revision
gradle-wrapper.properties
-
Jan Gruteser authoredJan Gruteser authored
Code owners
Assign users and groups as approvers for specific file changes. Learn more.
build.gradle 4.44 KiB
plugins {
id 'java'
id 'eclipse'
id 'maven'
id 'jacoco'
id "de.undercouch.download" version "3.4.3"
}
project.version = '1.0.5-SNAPSHOT'
project.group = 'de.hhu.stups'
project.sourceCompatibility = '1.7'
project.targetCompatibility = '1.7'
wrapper {
gradleVersion = "5.6.4"
}
repositories {
mavenCentral()
maven {
name "sonatype snapshots"
url "https://oss.sonatype.org/content/repositories/snapshots"
}
}
configurations.all {
resolutionStrategy.cacheChangingModulesFor 0, 'seconds'
}
def parser_version = '2.9.14'
def tlatools_version = '1.0.2'
dependencies {
//compile (group: 'com.microsoft', name: 'tla2tools', version: '1.4.6')
compile 'commons-cli:commons-cli:1.2'
compile (group: 'de.hhu.stups', name: 'tlatools', version: tlatools_version)
compile (group: 'de.hhu.stups', name: 'prologlib', version: parser_version)
compile (group: 'de.hhu.stups', name: 'parserbase', version: parser_version)
compile (group: 'de.hhu.stups', name: 'bparser', version: parser_version)
compile (group: 'de.hhu.stups', name: 'ltlparser', version: parser_version)
//compile(group: 'de.hhu.stups', name: 'de.prob.core.kernel', version: '2.0.0-milestone-13-SNAPSHOT')
testCompile (group: 'junit', name: 'junit', version: '4.12')
testCompile (group: 'de.hhu.stups', name: 'tla2bAST', version: '1.1.0')
}
jacoco {
toolVersion = "0.8.7"
reportsDir = file("$buildDir/JacocoReports")
}
jacocoTestReport {
reports {
xml.enabled false
csv.enabled false
html.destination file("${buildDir}/jacocoHtml")
}
}
test {
exclude('de/tlc4b/tlc/integration/probprivate')
exclude('testing')
//exclude('de/tlc4b/tlc/integration')
}
task downloadPublicExamples(type: Download) {
src 'https://www3.hhu.de/stups/downloads/prob/source/ProB_public_examples.tgz'
dest buildDir
onlyIfModified true
}
task extractPublicExamples(dependsOn: downloadPublicExamples, type: Copy) {
from tarTree(resources.gzip("${buildDir}/ProB_public_examples.tgz"))
into projectDir
}
clean {
delete "${projectDir}/public_examples"
}
task regressionTests(dependsOn: extractPublicExamples, type: Test){
doFirst{ println("Running integration tests") }
scanForTestClasses = true
//include('de/tlc4b/tlc/integration/probprivate/**')
include('de/tlc4b/**')
}
check.dependsOn(regressionTests)
// type 'gradle integrationTests jacocoIntegrationTestReport' in order to run the jacoco code coverage analysis
task jacocoIntegrationTestReport(type: JacocoReport) {
sourceSets sourceSets.main
//executionData files('build/jacoco/integrationTests.exec')
executionData fileTree(project.rootDir.absolutePath).include("**/build/jacoco/*.exec")
}
task createJar(type: Jar, dependsOn: build){
archiveName = 'TLC4B.jar'
from sourceSets.main.output
from {configurations.compile.collect { it.isDirectory() ? it : zipTree(it) } }
exclude('**/*.java')
manifest {
attributes "Main-Class" : 'de.tlc4b.TLC4B'
}
}
if (project.hasProperty('ossrhUsername') && project.hasProperty('ossrhPassword')) {
apply plugin: 'signing'
signing {
sign configurations.archives
}
javadoc {
failOnError = false
}
task javadocJar(type: Jar) {
classifier = 'javadoc'
from javadoc
}
task sourcesJar(type: Jar) {
classifier = 'sources'
from sourceSets.main.allSource
}
artifacts {
archives javadocJar, sourcesJar
}
uploadArchives {
repositories {
mavenDeployer {
beforeDeployment { MavenDeployment deployment -> signing.signPom(deployment) }
repository(url: "https://oss.sonatype.org/service/local/staging/deploy/maven2/") {
authentication(userName: ossrhUsername, password: ossrhPassword)
}
snapshotRepository(url: "https://oss.sonatype.org/content/repositories/snapshots/") {
authentication(userName: ossrhUsername, password: ossrhPassword)
}
pom.project {
name 'TLC integration into ProB'
packaging 'jar'
// optionally artifactId can be defined here
description "Use the TLC model checker within ProB."
url 'https://github.com/hhu-stups/tlc4b'
licenses {
license {
name 'Eclipse Public License, Version 2.1'
url 'https://www.eclipse.org/legal/epl-v10.html'
}
}
scm {
connection 'scm:git:git://github.com/hhu-stups/tlc4b.git'
developerConnection 'scm:git:git@github.com:hhu-stups/tlc4b.git'
url 'https://github.com/bendisposto/hhu-stups/tlc4b'
}
developers {
developer {
id 'bendisposto'
name 'Jens Bendisposto'
email 'jens@bendisposto.de'
}
}
}
}
}
}
}