-
Notifications
You must be signed in to change notification settings - Fork 327
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #740 from ge0ffrey/merge-repo-jbake-maven-plugin
Add repo jbake-maven-plugin into repo jbake + upgrade to gradle 7
- Loading branch information
Showing
26 changed files
with
1,109 additions
and
294 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
plugins { | ||
id 'groovy-gradle-plugin' | ||
} |
Empty file.
97 changes: 97 additions & 0 deletions
97
buildSrc/src/main/groovy/org/jbake/convention/org.jbake.convention.java-common.gradle
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,97 @@ | ||
plugins { | ||
id 'java' | ||
id 'jacoco' | ||
id 'checkstyle' | ||
} | ||
|
||
repositories { | ||
mavenCentral() | ||
} | ||
|
||
dependencies { | ||
implementation "org.slf4j:slf4j-api:$slf4jVersion" | ||
implementation "org.slf4j:jul-to-slf4j:$slf4jVersion" | ||
implementation "org.slf4j:jcl-over-slf4j:$slf4jVersion" | ||
implementation "ch.qos.logback:logback-classic:$logbackVersion" | ||
implementation "ch.qos.logback:logback-core:$logbackVersion" | ||
|
||
testImplementation "org.junit-pioneer:junit-pioneer:$junitPioneer" | ||
testImplementation "org.junit.jupiter:junit-jupiter-api:$junit5Version" | ||
testRuntimeOnly "org.junit.jupiter:junit-jupiter-engine:$junit5Version" | ||
// compatibility for Junit 4 test | ||
testCompileOnly "junit:junit:$junit4Version" | ||
testRuntimeOnly "org.junit.vintage:junit-vintage-engine:$junit5Version" | ||
|
||
testImplementation "org.assertj:assertj-core:$assertjCoreVersion" | ||
testImplementation "org.mockito:mockito-core:$mockitoVersion" | ||
testImplementation "org.mockito:mockito-junit-jupiter:$mockitoVersion" | ||
testImplementation 'org.itsallcode:junit5-system-extensions:1.1.0' | ||
} | ||
|
||
tasks.withType(JavaCompile) { | ||
sourceCompatibility = 1.8 | ||
targetCompatibility = 1.8 | ||
} | ||
|
||
//set jvm for all Test tasks (like test and smokeTest) | ||
tasks.withType(Test) { | ||
|
||
def args = ['-Xms512m', '-Xmx3g', '-Dorientdb.installCustomFormatter=false=false', '-Djna.nosys=true'] | ||
|
||
/** | ||
* jdk9 build is unable to determine the amount of MaxDirectMemorySize | ||
* See https://pastebin.com/ECvQeHx0 | ||
*/ | ||
if (JavaVersion.current().java9Compatible) { | ||
args << '-XX:MaxDirectMemorySize=2g' | ||
} | ||
jvmArgs args | ||
} | ||
|
||
task javadocJar(type: Jar) { | ||
archiveClassifier.set('javadoc') | ||
from javadoc | ||
} | ||
|
||
task sourcesJar(type: Jar) { | ||
archiveClassifier.set('sources') | ||
from sourceSets.main.allSource | ||
} | ||
|
||
tasks.withType(AbstractArchiveTask) { | ||
preserveFileTimestamps = false | ||
reproducibleFileOrder = true | ||
} | ||
|
||
test { | ||
useJUnitPlatform() | ||
|
||
testLogging { | ||
events "passed", "skipped", "failed" | ||
exceptionFormat "full" | ||
} | ||
|
||
jacoco { | ||
excludes = ["**/*OrientSqlTokenManager*"] | ||
} | ||
} | ||
|
||
jacoco { | ||
toolVersion = jacocoVersion | ||
} | ||
|
||
jacocoTestReport { | ||
reports { | ||
xml.required.set true // coveralls plugin depends on xml format report | ||
html.required.set true | ||
} | ||
} | ||
|
||
jacocoTestReport.dependsOn test | ||
|
||
tasks.withType(Checkstyle) { | ||
reports { | ||
xml.enabled false | ||
html.enabled true | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,3 @@ | ||
apply plugin: 'application' | ||
|
||
mainClassName = "org.jbake.launcher.Main" | ||
applicationName = "jbake" | ||
|
||
|
Oops, something went wrong.