xtext-core/gradle/maven-deployment.gradle
Christian Dietrich 9b61f32c53 [eclipse/xtext#1652] Use https instead of git URL for SCM connection
Harmonized newline at eof in gradle and poms

Signed-off-by: Christian Dietrich <christian.dietrich@itemis.de>
2020-12-04 08:42:16 +01:00

45 lines
1.6 KiB
Groovy

/*
* Configuration of deployment to Maven repositories.
*/
def noJavaDoc = name.endsWith('tests') || name.contains('testlanguage')
publishing {
publications {
LocalMavenRepo(MavenPublication) {
from components.java
artifact sourcesJar
if (!noJavaDoc) {
artifact javadocJar
}
pom {
url = 'https://www.eclipse.org/Xtext/'
licenses {
license {
name = 'Eclipse Public License, Version 2.0'
url = 'http://www.eclipse.org/legal/epl-2.0'
}
}
scm {
connection = "scm:git:https://github.com/eclipse/${rootProject.name}.git"
developerConnection = "scm:git:https://github.com/eclipse/${rootProject.name}.git"
url = "git@github.com:eclipse/${rootProject.name}.git"
}
// We need to wait until the project's own build file has been executed
// so we can use the title and description settings for setting up Maven publishing.
afterEvaluate {
if (project.hasProperty('title')) {
name = project.title
description = project.description
}
}
}
apply from: "${rootDir}/gradle/developers.gradle", to: pom
}
}
repositories {
maven {
url = "$rootProject.buildDir/maven-repository"
}
}
}