diff options
author | Jan Christopher Vogt <oss.nsp@cvogt.org> | 2016-07-08 15:31:54 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-07-08 15:31:54 -0400 |
commit | b1c30f1afdbdf8b0f6ddf226a497df3c3ed21d73 (patch) | |
tree | 798c0b6a2164b4fb8b3a2f4355ac898b1fd55698 | |
parent | c07b2e2dc582a5354fdd47b75236d1d221b98c91 (diff) | |
parent | b5d86995128a45c33117ecfb7365f0eb2b450a61 (diff) | |
download | cbt-b1c30f1afdbdf8b0f6ddf226a497df3c3ed21d73.tar.gz cbt-b1c30f1afdbdf8b0f6ddf226a497df3c3ed21d73.tar.bz2 cbt-b1c30f1afdbdf8b0f6ddf226a497df3c3ed21d73.zip |
Merge pull request #205 from cvogt/fix-pom-org
fix Organization and url in pom file
-rw-r--r-- | stage2/Lib.scala | 102 |
1 files changed, 50 insertions, 52 deletions
diff --git a/stage2/Lib.scala b/stage2/Lib.scala index 81d36f3..118c9a4 100644 --- a/stage2/Lib.scala +++ b/stage2/Lib.scala @@ -298,58 +298,56 @@ final class Lib(logger: Logger) extends Stage1Lib(logger) with Scaffold{ jarTarget: File ): File = { val xml = - <project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://maven.apache.org/POM/4.0.0"> - <modelVersion>4.0.0</modelVersion> - <groupId>{groupId}</groupId> - <artifactId>{artifactId ++ "_" ++ scalaMajorVersion}</artifactId> - <version>{version}</version> - <packaging>jar</packaging> - <name>{name}</name> - <description>{description}</description> - <url>{url}</url> - <licenses> - {licenses.map{ license => - <license> - <name>{license.name}</name> - <url>{license.url}</url> - <distribution>repo</distribution> - </license> - }} - </licenses> - <developers> - {developers.map{ developer => - <developer> - <id>{developer.id}</id> - <name>{developer.name}</name> - <timezone>{developer.timezone}</timezone> - <url>{developer.url}</url> - </developer> - }} - </developers> - <scm> - <url>{scmUrl}</url> - <connection>{scmConnection}</connection> - </scm> - <inceptionYear>{inceptionYear}</inceptionYear> - {organization.map{ org => - <organization> - <name>{org.name}</name> - {org.url.map( url => <url>url</url> )} - </organization> - }} - <dependencies> - { - dependencies.map{ - case d:ArtifactInfo => - <dependency> - <groupId>{d.groupId}</groupId> - <artifactId>{d.artifactId}</artifactId> - <version>{d.version}</version> - </dependency> - } - } - </dependencies> - </project> +<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://maven.apache.org/POM/4.0.0"> + <modelVersion>4.0.0</modelVersion> + <groupId>{groupId}</groupId> + <artifactId>{artifactId ++ "_" ++ scalaMajorVersion}</artifactId> + <version>{version}</version> + <packaging>jar</packaging> + <name>{name}</name> + <description>{description}</description> + <url>{url}</url> + <licenses> + {licenses.map{ license => + <license> + <name>{license.name}</name> + {license.url.map(url => <url>url</url>).getOrElse( scala.xml.NodeSeq.Empty )} + <distribution>repo</distribution> + </license> + }} + </licenses> + <developers> + {developers.map{ developer => + <developer> + <id>{developer.id}</id> + <name>{developer.name}</name> + <timezone>{developer.timezone}</timezone> + <url>{developer.url}</url> + </developer> + }} + </developers> + <scm> + <url>{scmUrl}</url> + <connection>{scmConnection}</connection> + </scm> + <inceptionYear>{inceptionYear}</inceptionYear> + {organization.map{ org => + <organization> + <name>{org.name}</name> + {org.url.map( url => <url>url</url> ).getOrElse( scala.xml.NodeSeq.Empty )} + </organization> + }.getOrElse(scala.xml.NodeSeq.Empty)} + <dependencies> + {dependencies.map{ + case d:ArtifactInfo => + <dependency> + <groupId>{d.groupId}</groupId> + <artifactId>{d.artifactId}</artifactId> + <version>{d.version}</version> + </dependency> + }} + </dependencies> +</project> // FIXME: do not build this file name including scalaMajorVersion in multiple places val path = jarTarget.toString ++ ( "/" ++ artifactId++ "_" ++ scalaMajorVersion ++ "-" ++ version ++ ".pom" ) val file = new File(path) |