mirror of
https://github.com/corda/corda.git
synced 2025-06-05 00:50:52 +00:00
Publishing to jcenter possible via bintrayUpload (with the correct credentials) and corda now has a dependency on the published gradle plugin to allow the split.
This commit is contained in:
parent
8e342e81d3
commit
14ca7847d0
@ -21,6 +21,7 @@ buildscript {
|
|||||||
dependencies {
|
dependencies {
|
||||||
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
|
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
|
||||||
classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.4'
|
classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.4'
|
||||||
|
classpath 'net.corda.plugins:publish-utils:0.5'
|
||||||
|
|
||||||
// Can run 'gradle dependencyUpdates' to find new versions of things.
|
// Can run 'gradle dependencyUpdates' to find new versions of things.
|
||||||
classpath 'com.github.ben-manes:gradle-versions-plugin:0.12.0'
|
classpath 'com.github.ben-manes:gradle-versions-plugin:0.12.0'
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
apply plugin: 'kotlin'
|
apply plugin: 'kotlin'
|
||||||
apply plugin: QuasarPlugin
|
apply plugin: QuasarPlugin
|
||||||
// Applying the maven plugin means this will get installed locally when running "gradle install"
|
apply plugin: 'net.corda.plugins.publish-utils'
|
||||||
apply plugin: DefaultPublishTasks
|
|
||||||
|
|
||||||
buildscript {
|
buildscript {
|
||||||
repositories {
|
repositories {
|
||||||
|
@ -40,4 +40,4 @@ publishing {
|
|||||||
artifact javadocJar
|
artifact javadocJar
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -26,6 +26,7 @@ bintray {
|
|||||||
user = System.getenv('CORDA_BINTRAY_USER')
|
user = System.getenv('CORDA_BINTRAY_USER')
|
||||||
key = System.getenv('CORDA_BINTRAY_KEY')
|
key = System.getenv('CORDA_BINTRAY_KEY')
|
||||||
publications = ['publishUtils']
|
publications = ['publishUtils']
|
||||||
|
dryRun = false
|
||||||
pkg {
|
pkg {
|
||||||
repo = 'corda'
|
repo = 'corda'
|
||||||
name = 'publish-utils'
|
name = 'publish-utils'
|
||||||
@ -34,6 +35,8 @@ bintray {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
task(install, dependsOn: 'publishToMavenLocal')
|
||||||
|
|
||||||
publishing {
|
publishing {
|
||||||
publications {
|
publications {
|
||||||
publishUtils(MavenPublication) {
|
publishUtils(MavenPublication) {
|
||||||
@ -43,6 +46,26 @@ publishing {
|
|||||||
|
|
||||||
artifact sourceJar
|
artifact sourceJar
|
||||||
artifact javadocJar
|
artifact javadocJar
|
||||||
|
|
||||||
|
pom.withXml {
|
||||||
|
asNode().children().last() + {
|
||||||
|
resolveStrategy = Closure.DELEGATE_FIRST
|
||||||
|
name 'publish-utils'
|
||||||
|
description 'A small gradle plugin that adds a couple of convenience functions for publishing to Maven'
|
||||||
|
url 'https://github.com/corda/corda'
|
||||||
|
scm {
|
||||||
|
url 'https://github.com/corda/corda'
|
||||||
|
}
|
||||||
|
|
||||||
|
licenses {
|
||||||
|
license {
|
||||||
|
name 'Apache-2.0'
|
||||||
|
url 'https://www.apache.org/licenses/LICENSE-2.0'
|
||||||
|
distribution 'repo'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -8,7 +8,7 @@ import org.gradle.api.Project
|
|||||||
/**
|
/**
|
||||||
* A utility plugin that when applied will automatically create source and javadoc publishing tasks
|
* A utility plugin that when applied will automatically create source and javadoc publishing tasks
|
||||||
*/
|
*/
|
||||||
class DefaultPublishTasks implements Plugin<Project> {
|
class PublishTasks implements Plugin<Project> {
|
||||||
void apply(Project project) {
|
void apply(Project project) {
|
||||||
project.task("sourceJar", type: Jar, dependsOn: project.classes) {
|
project.task("sourceJar", type: Jar, dependsOn: project.classes) {
|
||||||
classifier = 'sources'
|
classifier = 'sources'
|
@ -1 +1 @@
|
|||||||
implementation-class=net.corda.plugins.DefaultPublishTasks
|
implementation-class=net.corda.plugins.PublishTasks
|
||||||
|
Loading…
x
Reference in New Issue
Block a user