-
-
Notifications
You must be signed in to change notification settings - Fork 481
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: allways apply the plugin-publish plugin to the Gradle plugin pro…
…ject #1588
- Loading branch information
1 parent
78a6dc8
commit e924d80
Showing
2 changed files
with
64 additions
and
62 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -55,11 +55,16 @@ subprojects { | |
apply plugin: 'jacoco' | ||
apply plugin: 'org.jetbrains.kotlin.jvm' | ||
apply plugin: 'io.gitlab.arturbosch.detekt' | ||
if (System.env.TRAVIS != 'true') { | ||
if (System.env.CI != 'true') { | ||
apply plugin: 'org.jetbrains.dokka' | ||
} | ||
//apply plugin: "org.javamodularity.moduleplugin" | ||
|
||
dependencies { | ||
implementation "org.jetbrains.kotlin:kotlin-stdlib:$kotlinVersion" | ||
implementation "org.jetbrains.kotlin:kotlin-reflect:$kotlinVersion" | ||
} | ||
|
||
compileTestGroovy { | ||
classpath = classpath.plus(files(compileTestKotlin.destinationDir)) | ||
dependsOn compileTestKotlin | ||
|
@@ -101,11 +106,13 @@ subprojects { | |
if (System.env.CI != 'true') { | ||
task javadocJar(type: Jar, dependsOn: [javadoc, groovydoc, dokkaJavadoc]) { | ||
archiveClassifier = 'javadoc' | ||
duplicatesStrategy = 'exclude' | ||
from javadoc.destinationDir, groovydoc.destinationDir, dokkaJavadoc.outputDirectory | ||
} | ||
} else { | ||
task javadocJar(type: Jar, dependsOn: [javadoc, groovydoc]) { | ||
archiveClassifier = 'javadoc' | ||
duplicatesStrategy = 'exclude' | ||
from javadoc.destinationDir, groovydoc.destinationDir | ||
} | ||
} | ||
|
@@ -125,7 +132,7 @@ subprojects { | |
showExceptions true | ||
showStackTraces true | ||
showStandardStreams false | ||
events "passed", "skipped", "failed" //, "standardOut", "standardError" | ||
events "passed", "skipped", "failed" | ||
} | ||
} else { | ||
// Show test results. | ||
|
@@ -138,60 +145,61 @@ subprojects { | |
systemProperty 'pact_do_not_track', 'true' | ||
} | ||
|
||
publishing { | ||
publications { | ||
mavenPublication(MavenPublication) { | ||
from components.java | ||
if (!project.hasProperty('isGradleRelease')) { | ||
// Gradle plugin plugin will automatically add these | ||
if (name != 'gradle') { | ||
publishing { | ||
publications { | ||
mavenPublication(MavenPublication) { | ||
from components.java | ||
artifact sourceJar | ||
artifact javadocJar | ||
} | ||
pom { | ||
name = project.name | ||
description = StringEscapeUtils.escapeXml11(new File(projectDir, 'README.md').text) | ||
url = 'https://github.com/DiUS/pact-jvm' | ||
licenses { | ||
license { | ||
name = 'Apache 2' | ||
url = 'http://www.apache.org/licenses/LICENSE-2.0.txt' | ||
distribution = 'repo' | ||
} | ||
} | ||
scm { | ||
url = 'https://github.com/DiUS/pact-jvm' | ||
connection = 'https://github.com/DiUS/pact-jvm.git' | ||
} | ||
|
||
developers { | ||
developer { | ||
id = 'thetrav' | ||
name = 'Travis Dixon' | ||
email = '[email protected]' | ||
pom { | ||
name = project.name | ||
description = StringEscapeUtils.escapeXml11(new File(projectDir, 'README.md').text) | ||
url = 'https://github.com/DiUS/pact-jvm' | ||
licenses { | ||
license { | ||
name = 'Apache 2' | ||
url = 'http://www.apache.org/licenses/LICENSE-2.0.txt' | ||
distribution = 'repo' | ||
} | ||
} | ||
developer { | ||
id = 'rholshausen' | ||
name = 'Ronald Holshausen' | ||
email = '[email protected]' | ||
scm { | ||
url = 'https://github.com/pact-foundation/pact-jvm' | ||
connection = 'https://github.com/pact-foundation/pact-jvm.git' | ||
} | ||
|
||
developers { | ||
developer { | ||
id = 'thetrav' | ||
name = 'Travis Dixon' | ||
email = '[email protected]' | ||
} | ||
developer { | ||
id = 'rholshausen' | ||
name = 'Ronald Holshausen' | ||
email = '[email protected]' | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} | ||
repositories { | ||
maven { | ||
url "https://oss.sonatype.org/service/local/staging/deploy/maven2" | ||
if (project.hasProperty('sonatypeUsername')) { | ||
credentials { | ||
username sonatypeUsername | ||
password sonatypePassword | ||
repositories { | ||
maven { | ||
url "https://oss.sonatype.org/service/local/staging/deploy/maven2" | ||
if (project.hasProperty('sonatypeUsername')) { | ||
credentials { | ||
username sonatypeUsername | ||
password sonatypePassword | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} | ||
|
||
if (System.env.CI != 'true') { | ||
signing { | ||
required { project.hasProperty('isRelease') } | ||
sign publishing.publications.mavenPublication | ||
} | ||
} | ||
|
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