Merge branch 'feature/simplifyReleasing'

Conflicts:
	gradle/release.gradle
This commit is contained in:
Marcin Zajaczkowski
2015-09-02 23:42:51 +02:00
2 changed files with 38 additions and 87 deletions

View File

@@ -5,17 +5,12 @@ buildscript {
}
dependencies {
classpath "pl.allegro.tech.build:axion-release-plugin:1.2.2"
classpath "com.bmuschko:gradle-nexus-plugin:2.3"
classpath "io.codearte.gradle.nexus:gradle-nexus-staging-plugin:0.5.3"
}
}
apply plugin: "pl.allegro.tech.build.axion-release"
apply plugin: 'io.codearte.nexus-staging'
nexusStaging {
packageGroup = "io.codearte"
stagingProfileId = '93c08fdebde1ff'
}
scmVersion {
tag { prefix = "accurest" }
@@ -34,11 +29,7 @@ allprojects {
subprojects {
apply plugin: 'groovy'
apply plugin: 'maven-publish'
if (!version.contains('SNAPSHOT')) {
apply from: "$rootDir/gradle/release.gradle"
}
apply from: "$rootDir/gradle/release.gradle"
group = 'io.codearte.accurest'
@@ -61,27 +52,6 @@ subprojects {
exclude(group: 'org.codehaus.groovy')
}
}
publishing {
publications {
maven(MavenPublication) {
from components.java
pom.withXml {
//#89 - workaround to not to have only runtime dependencies in generated pom.xml
//Known limitation in maven-publish - - http://forums.gradle.org/gradle/topics/maven_publish_plugin_generated_pom_making_dependency_scope_runtime#reply_14120711
asNode().dependencies.'*'.findAll() {
it.scope.text() == 'runtime' && project.configurations.compile.allDependencies.find { dep ->
dep.name == it.artifactId.text()
}
}.each() {
it.scope*.value = 'compile'
}
}
}
}
}
uploadArchives.dependsOn { check }
}
project(':accurest-core') {

View File

@@ -1,64 +1,45 @@
apply plugin: 'maven'
apply plugin: 'signing'
apply plugin: 'com.bmuschko.nexus'
apply plugin: 'io.codearte.nexus-staging'
task javadocJar(type: Jar) {
classifier = 'javadoc'
from javadoc
}
modifyPom {
project {
name "$project.name"
packaging 'jar'
description 'RESTful Contract Verifier'
url 'https://github.com/Codearte/accurest'
inceptionYear '2014'
task sourcesJar(type: Jar) {
classifier = 'sources'
from sourceSets.main.allSource
}
scm {
connection 'scm:git:git@github.com:Codearte/accurest.git'
developerConnection 'scm:git:git@github.com:Codearte/accurest.git'
url 'https://github.com/Codearte/accurest'
}
artifacts {
archives javadocJar, sourcesJar, repackagedJar
}
signing {
sign configurations.archives
}
uploadArchives {
repositories {
mavenDeployer {
beforeDeployment { MavenDeployment deployment -> signing.signPom(deployment) }
repository(url: "https://oss.sonatype.org/service/local/staging/deploy/maven2/") {
authentication(userName: nexusUsername, password: nexusPassword)
licenses {
license {
name 'The Apache License, Version 2.0'
url 'http://www.apache.org/licenses/LICENSE-2.0.txt'
}
}
snapshotRepository(url: "https://oss.sonatype.org/content/repositories/snapshots/") {
authentication(userName: nexusUsername, password: nexusPassword)
developers {
developer {
id 'jkubrynski'
name 'Jakub Kubrynski'
email 'jk ATT codearte DOTT io'
}
pom.project {
name "$project.name"
packaging 'jar'
description 'RESTful Contract Verifier'
url 'http://codearte.github.io/accurest'
scm {
connection 'scm:git:git@github.com:Codearte/accurest.git'
developerConnection 'scm:git:git@github.com:Codearte/accurest.git'
url 'https://github.com/Codearte/accurest'
}
licenses {
license {
name 'The Apache License, Version 2.0'
url 'http://www.apache.org/licenses/LICENSE-2.0.txt'
}
}
developers {
developer {
id 'jkubrynski'
name 'Jakub Kubrynski'
email 'jk ATT codearte DOTT io'
}
}
developer {
id 'marcingrzejszczak'
name 'Marcin Grzejszczak'
email 'marcin ATT grzejszczak DOTT pl'
}
}
}
}
}
uploadArchives.dependsOn { check }
nexusStaging {
packageGroup = "io.codearte"
stagingProfileId = '93c08fdebde1ff'
}