Change Gradle build
This commit is contained in:
+33
-70
@@ -1,86 +1,49 @@
|
||||
buildscript {
|
||||
repositories {
|
||||
jcenter()
|
||||
maven {
|
||||
url "https://plugins.gradle.org/m2/"
|
||||
}
|
||||
}
|
||||
dependencies {
|
||||
classpath 'org.asciidoctor:asciidoctor-gradle-plugin:1.5.7'
|
||||
//classpath 'org.asciidoctor:asciidoctorj-epub3:1.5.0-alpha.6'
|
||||
classpath ('org.asciidoctor:asciidoctorj-pdf:1.5.0-alpha.16') {
|
||||
exclude group: 'org.jruby'
|
||||
}
|
||||
classpath 'org.jruby:jruby:9.1.17.0'
|
||||
}
|
||||
plugins {
|
||||
id 'org.asciidoctor.jvm.pdf' version '3.1.0'
|
||||
id 'org.asciidoctor.jvm.gems' version '3.1.0'
|
||||
}
|
||||
|
||||
apply plugin: 'org.asciidoctor.convert'
|
||||
apply plugin: 'java'
|
||||
apply plugin: 'maven'
|
||||
apply plugin: 'checkstyle'
|
||||
apply plugin: 'pmd'
|
||||
apply plugin: 'project-report'
|
||||
|
||||
description = 'Introduction to documentation'
|
||||
version = '1.0.0-SNAPSHOT'
|
||||
|
||||
repositories {
|
||||
mavenCentral()
|
||||
jcenter()
|
||||
ruby.gems()
|
||||
}
|
||||
|
||||
sourceCompatibility = 1.8
|
||||
group = 'com.ibtp'
|
||||
version = '0.0.1-SNAPSHOT'
|
||||
description = 'Project Generations: Generative Programmierung in Java'
|
||||
|
||||
final BUILD_DATE = new Date().format('dd.MM.yyyy').toString()
|
||||
|
||||
asciidoctorj {
|
||||
version = '1.6.0-alpha.7'
|
||||
}
|
||||
|
||||
asciidoctor {
|
||||
backends 'html5', 'pdf'
|
||||
attributes 'build-gradle': file('build.gradle'),
|
||||
'source-highlighter': 'coderay',
|
||||
'toc': 'left',
|
||||
'toc-title': 'Inhaltsverzeichnis',
|
||||
'revdate': BUILD_DATE,
|
||||
'revnumber': version,
|
||||
'idprefix': 'id_',
|
||||
'chapter-label': '',
|
||||
'icons': 'font',
|
||||
'setanchors': '',
|
||||
'idseparator': '-',
|
||||
'endpoint-url': 'http://www.ingenieurbuero-peetz.de',
|
||||
'imagesdir': './images',
|
||||
'docinfo1': ''
|
||||
}
|
||||
|
||||
build.dependsOn(['asciidoctor'])
|
||||
|
||||
dependencies {
|
||||
compile 'org.slf4j:slf4j-api:1.7.22'
|
||||
testCompile 'junit:junit:4.12'
|
||||
testCompile 'org.mockito:mockito-all:1.9.5'
|
||||
asciidoctorGems 'rubygems:rouge:3.15.0'
|
||||
}
|
||||
|
||||
checkstyle {
|
||||
ignoreFailures = true
|
||||
showViolations = false
|
||||
final BUILD_DATE = new Date().format('dd.MM.yyyy').toString()
|
||||
final DOK_VERSION = version
|
||||
|
||||
asciidoctorPdf {
|
||||
dependsOn asciidoctorGemsPrepare
|
||||
|
||||
baseDirFollowsSourceFile()
|
||||
|
||||
asciidoctorj {
|
||||
attributes 'build-gradle': file('build.gradle'),
|
||||
'revdate': BUILD_DATE,
|
||||
'revnumber': DOK_VERSION,
|
||||
'endpoint-url': 'http://www.ingenieurbuero-peetz.de',
|
||||
'imagesdir': './images',
|
||||
'toc-title': 'Inhaltsverzeichnis',
|
||||
'chapter-label': '',
|
||||
'icons': 'font',
|
||||
'idprefix': 'id_',
|
||||
'idseparator': '-',
|
||||
'setanchors': '',
|
||||
'docinfo1': ''
|
||||
}
|
||||
}
|
||||
|
||||
pmd {
|
||||
ignoreFailures = true
|
||||
ruleSets = ["basic", "braces", "junit"]
|
||||
}
|
||||
|
||||
jar {
|
||||
manifest {
|
||||
attributes 'Implementation-Title': 'Generations', 'Implementation-Version': version
|
||||
}
|
||||
}
|
||||
task asciidoctor(dependsOn: asciidoctorPdf)
|
||||
build.dependsOn(['asciidoctor'])
|
||||
|
||||
wrapper {
|
||||
gradleVersion = "5.6.1"
|
||||
gradleVersion = "6.3"
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user