Updated comments in build script
This commit is contained in:
parent
0e42fb89af
commit
fbc253d3fc
@ -30,6 +30,14 @@ import java.net.*
|
|||||||
import java.nio.charset.StandardCharsets.UTF_8
|
import java.nio.charset.StandardCharsets.UTF_8
|
||||||
import kotlin.reflect.KMutableProperty
|
import kotlin.reflect.KMutableProperty
|
||||||
|
|
||||||
|
///////////////////////////////
|
||||||
|
////// PUBLISH TO SONATYPE / MAVEN CENTRAL
|
||||||
|
//////
|
||||||
|
////// TESTING : local maven repo <PUBLISHING - publishToMavenLocal>
|
||||||
|
//////
|
||||||
|
////// RELEASE : sonatype / maven central, <PUBLISHING - publish> then <RELEASE - closeAndReleaseRepository>
|
||||||
|
///////////////////////////////
|
||||||
|
|
||||||
println("\tGradle ${project.gradle.gradleVersion}")
|
println("\tGradle ${project.gradle.gradleVersion}")
|
||||||
|
|
||||||
plugins {
|
plugins {
|
||||||
@ -260,11 +268,12 @@ tasks.compileJava.get().apply {
|
|||||||
println("\tCompiling classes to Java $sourceCompatibility")
|
println("\tCompiling classes to Java $sourceCompatibility")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
///////////////////////////////
|
///////////////////////////////
|
||||||
////// UTILITIES COMPILE
|
////// UTILITIES COMPILE
|
||||||
///////////////////////////////
|
///////////////////////////////
|
||||||
|
|
||||||
// as long as the 'Utilities' project is ALSO imported into IntelliJ, class resolution will work
|
// as long as the 'Utilities' project is ALSO imported into IntelliJ, class resolution will work (add the sources in the intellij project)
|
||||||
val utils : Configuration by configurations.creating
|
val utils : Configuration by configurations.creating
|
||||||
|
|
||||||
fun javaFile(vararg fileNames: String): Iterable<String> {
|
fun javaFile(vararg fileNames: String): Iterable<String> {
|
||||||
@ -391,7 +400,6 @@ dependencies {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
///////////////////////////////
|
///////////////////////////////
|
||||||
////// Jar Tasks
|
////// Jar Tasks
|
||||||
///////////////////////////////
|
///////////////////////////////
|
||||||
@ -413,8 +421,13 @@ tasks.jar.get().apply {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
///////////////////////////////
|
///////////////////////////////
|
||||||
////// Maven Publishing + Release
|
////// PUBLISH TO SONATYPE / MAVEN CENTRAL
|
||||||
|
//////
|
||||||
|
////// TESTING : local maven repo <PUBLISHING - publishToMavenLocal>
|
||||||
|
//////
|
||||||
|
////// RELEASE : sonatype / maven central, <PUBLISHING - publish> then <RELEASE - closeAndReleaseRepository>
|
||||||
///////////////////////////////
|
///////////////////////////////
|
||||||
val sourceJar = task<Jar>("sourceJar") {
|
val sourceJar = task<Jar>("sourceJar") {
|
||||||
description = "Creates a JAR that contains the source code."
|
description = "Creates a JAR that contains the source code."
|
||||||
@ -430,14 +443,6 @@ val javaDocJar = task<Jar>("javaDocJar") {
|
|||||||
archiveClassifier.set("javadoc")
|
archiveClassifier.set("javadoc")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
///////////////////////////////
|
|
||||||
////// PUBLISH TO SONATYPE / MAVEN CENTRAL
|
|
||||||
//////
|
|
||||||
////// TESTING : local maven repo <PUBLISHING - publishToMavenLocal>
|
|
||||||
//////
|
|
||||||
////// RELEASE : sonatype / maven central, <PUBLISHING - publish> then <RELEASE - CloseAndReleaseRepository>
|
|
||||||
///////////////////////////////
|
|
||||||
publishing {
|
publishing {
|
||||||
publications {
|
publications {
|
||||||
create<MavenPublication>("maven") {
|
create<MavenPublication>("maven") {
|
||||||
@ -523,6 +528,8 @@ signing {
|
|||||||
sign(publishing.publications["maven"])
|
sign(publishing.publications["maven"])
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
///////////////////////////////
|
///////////////////////////////
|
||||||
///// Prevent anything other than a release from showing version updates
|
///// Prevent anything other than a release from showing version updates
|
||||||
//// https://github.com/ben-manes/gradle-versions-plugin/blob/master/README.md
|
//// https://github.com/ben-manes/gradle-versions-plugin/blob/master/README.md
|
||||||
@ -545,6 +552,7 @@ tasks.named<DependencyUpdatesTask>("dependencyUpdates") {
|
|||||||
checkForGradleUpdate = true
|
checkForGradleUpdate = true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
///////////////////////////////
|
///////////////////////////////
|
||||||
////// Gradle Wrapper Configuration.
|
////// Gradle Wrapper Configuration.
|
||||||
///// Run this task, then refresh the gradle project
|
///// Run this task, then refresh the gradle project
|
||||||
@ -553,5 +561,3 @@ val wrapperUpdate by tasks.creating(Wrapper::class) {
|
|||||||
gradleVersion = "5.1.1"
|
gradleVersion = "5.1.1"
|
||||||
distributionUrl = distributionUrl.replace("bin", "all")
|
distributionUrl = distributionUrl.replace("bin", "all")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user