Skip to content

Commit

Permalink
add pom developer url support (#88)
Browse files Browse the repository at this point in the history
  • Loading branch information
gabrielittner authored Jan 25, 2020
1 parent fe49d77 commit eb962d7
Show file tree
Hide file tree
Showing 11 changed files with 20 additions and 8 deletions.
1 change: 1 addition & 0 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -19,3 +19,4 @@ POM_LICENCE_DIST=repo

POM_DEVELOPER_ID=vanniktech
POM_DEVELOPER_NAME=Niklas Baudy
POM_DEVELOPER_URL=https://github.com/vanniktech/
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,12 @@
<developer>
<id>vanniktech</id>
<name>Niklas Baudy</name>
<url>https://github.com/vanniktech/</url>
</developer>
</developers>
<scm>
<connection>scm:git:git://github.com/vanniktech/gradle-maven-publish-plugin.git</connection>
<developerConnection>scm:git:ssh://git@github.com/vanniktech/gradle-maven-publish-plugin.git</developerConnection>
<url>https://github.com/vanniktech/gradle-maven-publish-plugin/</url>
</scm>
</project>
</project>
1 change: 1 addition & 0 deletions src/integrationTest/fixtures/common/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ POM_LICENCE_DIST=repo

POM_DEVELOPER_ID=vanniktech
POM_DEVELOPER_NAME=Niklas Baudy
POM_DEVELOPER_URL=https://github.com/vanniktech/

signing.keyId=B89C4055
signing.password=test
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,12 @@
<developer>
<id>vanniktech</id>
<name>Niklas Baudy</name>
<url>https://github.com/vanniktech/</url>
</developer>
</developers>
<scm>
<connection>scm:git:git://github.com/vanniktech/gradle-maven-publish-plugin.git</connection>
<developerConnection>scm:git:ssh://git@github.com/vanniktech/gradle-maven-publish-plugin.git</developerConnection>
<url>https://github.com/vanniktech/gradle-maven-publish-plugin/</url>
</scm>
</project>
</project>
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
<developer>
<id>vanniktech</id>
<name>Niklas Baudy</name>
<url>https://github.com/vanniktech/</url>
</developer>
</developers>
<scm>
Expand All @@ -34,4 +35,4 @@
<scope>compile</scope>
</dependency>
</dependencies>
</project>
</project>
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
<developer>
<id>vanniktech</id>
<name>Niklas Baudy</name>
<url>https://github.com/vanniktech/</url>
</developer>
</developers>
<scm>
Expand All @@ -34,4 +35,4 @@
<scope>compile</scope>
</dependency>
</dependencies>
</project>
</project>
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
<developer>
<id>vanniktech</id>
<name>Niklas Baudy</name>
<url>https://github.com/vanniktech/</url>
</developer>
</developers>
<scm>
Expand All @@ -33,4 +34,4 @@
<scope>compile</scope>
</dependency>
</dependencies>
</project>
</project>
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
<developer>
<id>vanniktech</id>
<name>Niklas Baudy</name>
<url>https://github.com/vanniktech/</url>
</developer>
</developers>
<scm>
Expand All @@ -33,4 +34,4 @@
<scope>compile</scope>
</dependency>
</dependencies>
</project>
</project>
Original file line number Diff line number Diff line change
Expand Up @@ -187,6 +187,7 @@ class MavenPublishPlugin extends BaseMavenPublishPlugin {
developer {
id publishPom.developerId
name publishPom.developerName
url publishPom.developerUrl
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ internal class MavenPublishConfigurer(private val project: Project) : Configurer
developers.developer {
it.id.set(publishPom.developerId)
it.name.set(publishPom.developerName)
it.url.set(publishPom.developerUrl)
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,8 @@ internal data class MavenPublishPom(
val licenseDistribution: String?,

val developerId: String?,
val developerName: String?
val developerName: String?,
val developerUrl: String?
) {

internal companion object {
Expand All @@ -41,7 +42,8 @@ internal data class MavenPublishPom(
findOptionalProperty(project, "POM_LICENCE_URL"),
findOptionalProperty(project, "POM_LICENCE_DIST"),
findOptionalProperty(project, "POM_DEVELOPER_ID"),
findOptionalProperty(project, "POM_DEVELOPER_NAME")
findOptionalProperty(project, "POM_DEVELOPER_NAME"),
findOptionalProperty(project, "POM_DEVELOPER_URL")
)

private fun findMandatoryProperty(project: Project, propertyName: String): String {
Expand Down

0 comments on commit eb962d7

Please sign in to comment.