Simplify Gson poms.

A lot of the configuration in these poms has been taken over by improvements
to the Maven release plugin.
This commit is contained in:
jwilson 2016-02-11 12:47:25 -05:00
parent 7c65a225f5
commit 2016e9553e
2 changed files with 91 additions and 453 deletions

View File

@ -1,246 +1,36 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>
<groupId>com.google.code.gson</groupId>
<artifactId>gson</artifactId>
<packaging>jar</packaging>
<version>2.6-SNAPSHOT</version>
<inceptionYear>2008</inceptionYear>
<name>Gson</name>
<parent> <parent>
<groupId>org.sonatype.oss</groupId> <groupId>com.google.code.gson</groupId>
<artifactId>oss-parent</artifactId> <artifactId>gson-parent</artifactId>
<version>9</version> <version>2.6-SNAPSHOT</version>
<relativePath />
</parent> </parent>
<url>https://github.com/google/gson</url>
<description>Google Gson: Java to JSON conversion library</description> <artifactId>gson</artifactId>
<properties> <name>Gson</name>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>
<licenses>
<license>
<name>The Apache Software License, Version 2.0</name>
<url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
<distribution>repo</distribution>
</license>
</licenses>
<scm>
<connection>scm:git:https://github.com/google/gson.git</connection>
<developerConnection>scm:git:https://github.com/google/gson.git</developerConnection>
<url>https://github.com/google/gson</url>
<tag>gson-${project.version}</tag>
</scm>
<issueManagement>
<system>Github Issue Tracking</system>
<url>https://github.com/google/gson/issues</url>
</issueManagement>
<distributionManagement>
<snapshotRepository>
<id>sonatype-nexus-snapshots</id>
<name>Sonatype Nexus Snapshots</name>
<url>https://oss.sonatype.org/content/repositories/snapshots/</url>
</snapshotRepository>
<repository>
<id>sonatype-nexus-staging</id>
<name>Nexus Release Repository</name>
<url>http://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
</repository>
</distributionManagement>
<organization>
<name>Google, Inc.</name>
<url>http://www.google.com</url>
</organization>
<dependencies> <dependencies>
<dependency> <dependency>
<groupId>junit</groupId> <groupId>junit</groupId>
<artifactId>junit</artifactId> <artifactId>junit</artifactId>
<version>3.8.2</version>
<scope>test</scope> <scope>test</scope>
</dependency> </dependency>
</dependencies> </dependencies>
<profiles>
<!-- Activate PGP signing only when performing a release -->
<profile>
<id>release-sign-artifacts</id>
<activation>
<property>
<name>performRelease</name>
<value>true</value>
</property>
</activation>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-gpg-plugin</artifactId>
<version>1.5</version>
<executions>
<execution>
<id>sign-artifacts</id>
<phase>verify</phase>
<goals>
<goal>sign</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
<profile>
<id>doclint-java8-disable</id>
<activation>
<jdk>[1.8,)</jdk>
</activation>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<configuration>
<additionalparam>-Xdoclint:none</additionalparam>
</configuration>
</plugin>
</plugins>
</build>
</profile>
</profiles>
<build> <build>
<defaultGoal>package</defaultGoal>
<plugins> <plugins>
<plugin> <plugin>
<groupId>org.apache.maven.plugins</groupId> <groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId> <artifactId>maven-javadoc-plugin</artifactId>
<version>3.3</version>
<configuration> <configuration>
<source>1.6</source> <includePackageNames>com.google.gson</includePackageNames>
<target>1.6</target> <excludePackageNames>com.google.gson.internal:com.google.gson.internal.bind</excludePackageNames>
</configuration> <links>
</plugin> <link>http://docs.oracle.com/javase/6/docs/api/</link>
<plugin> </links>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<version>2.6</version>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>jar</goal>
</goals>
</execution>
</executions>
<configuration>
<archive>
<addMavenDescriptor>false</addMavenDescriptor>
<manifestEntries>
<Bundle-RequiredExecutionEnvironment>J2SE-1.5, JavaSE-1.6, JavaSE-1.7, JavaSE-1.8</Bundle-RequiredExecutionEnvironment>
<Export-Package><![CDATA[com.google.gson;version=${project.version}, com.google.gson.annotations;version=${project.version}, com.google.gson.reflect;version=${project.version}, com.google.gson.stream;version=${project.version}, com.google.gson.internal;version=${project.version}, com.google.gson.internal.bind;version=${project.version}]]></Export-Package>
<Bundle-Version>${project.version}</Bundle-Version>
<Bundle-ContactAddress>https://github.com/google/gson</Bundle-ContactAddress>
<Bundle-Vendor>Google Gson Project</Bundle-Vendor>
<Bundle-Name>${project.name}</Bundle-Name>
<Bundle-Description>${project.description}</Bundle-Description>
<Bundle-ClassPath>.</Bundle-ClassPath>
<Bundle-ManifestVersion>2</Bundle-ManifestVersion>
<Bundle-SymbolicName>com.google.gson</Bundle-SymbolicName>
</manifestEntries>
</archive>
</configuration>
</plugin>
<plugin>
<!-- TODO(inder): add manifest entry for maven group, artifact, and classifier ids -->
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-source-plugin</artifactId>
<version>2.4</version>
<executions>
<execution>
<id>attach-sources</id>
<phase>verify</phase>
<goals>
<goal>jar</goal>
</goals>
</execution>
</executions>
<configuration>
<archive>
<manifestEntries>
<Eclipse-SourceBundle>com.google.gson;version="${project.version}"</Eclipse-SourceBundle>
<Bundle-SymbolicName>com.google.gson.source</Bundle-SymbolicName>
<Bundle-ManifestVersion>2</Bundle-ManifestVersion>
<Bundle-Version>${project.version}</Bundle-Version>
</manifestEntries>
</archive>
</configuration>
</plugin>
<plugin>
<!-- TODO(inder): add manifest entry for maven group, artifact, and classifier ids -->
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<version>2.10.3</version>
<executions>
<execution>
<id>attach-javadocs</id>
<goals>
<goal>jar</goal>
</goals>
</execution>
</executions>
<configuration>
<includePackageNames>com.google.gson</includePackageNames>
<excludePackageNames>com.google.gson.internal:com.google.gson.internal.bind</excludePackageNames>
<links>
<link>http://docs.oracle.com/javase/6/docs/api/</link>
</links>
<version>true</version>
<show>protected</show>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-eclipse-plugin</artifactId>
<version>2.10</version>
<configuration>
<downloadSources>true</downloadSources>
<downloadJavadocs>true</downloadJavadocs>
<workspace>
../eclipse-ws/
</workspace>
<workspaceCodeStylesURL>
file:///${basedir}/../lib/gson-formatting-styles.xml
</workspaceCodeStylesURL>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-release-plugin</artifactId>
<!-- version>2.5</version -->
<configuration>
<arguments>-DenableCiProfile=true</arguments>
</configuration>
</plugin>
<plugin>
<artifactId>maven-assembly-plugin</artifactId>
<version>2.5.5</version>
<configuration>
<descriptor>assembly-descriptor.xml</descriptor>
<finalName>google-gson-${project.version}</finalName>
<outputDirectory>target/dist</outputDirectory>
<workDirectory>target/assembly/work</workDirectory>
</configuration> </configuration>
</plugin> </plugin>
</plugins> </plugins>
</build> </build>
<developers>
<developer>
<name>Inderjeet Singh</name>
</developer>
<developer>
<name>Joel Leitch</name>
<organization>Google Inc.</organization>
</developer>
<developer>
<name>Jesse Wilson</name>
<organization>Square Inc.</organization>
</developer>
</developers>
</project> </project>

304
pom.xml
View File

@ -1,249 +1,97 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>
<groupId>com.google.code.gson</groupId>
<artifactId>gson-parent</artifactId>
<packaging>pom</packaging>
<version>2.6-SNAPSHOT</version>
<inceptionYear>2008</inceptionYear>
<name>Gson Parent</name>
<parent> <parent>
<groupId>org.sonatype.oss</groupId> <groupId>org.sonatype.oss</groupId>
<artifactId>oss-parent</artifactId> <artifactId>oss-parent</artifactId>
<version>9</version> <version>7</version>
<relativePath />
</parent> </parent>
<groupId>com.google.code.gson</groupId>
<artifactId>gson-parent</artifactId>
<version>2.6-SNAPSHOT</version>
<packaging>pom</packaging>
<name>Gson Parent</name>
<description>Gson JSON library</description>
<url>https://github.com/google/gson</url> <url>https://github.com/google/gson</url>
<description>Google Gson library</description>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>
<licenses>
<license>
<name>The Apache Software License, Version 2.0</name>
<url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
<distribution>repo</distribution>
</license>
</licenses>
<scm>
<connection>scm:git:https://github.com/google/gson.git</connection>
<developerConnection>scm:git:https://github.com/google/gson.git</developerConnection>
<url>https://github.com/google/gson</url>
<tag>gson-${project.version}</tag>
</scm>
<issueManagement>
<system>Github Issue Tracking</system>
<url>https://github.com/google/gson/issues</url>
</issueManagement>
<distributionManagement>
<snapshotRepository>
<id>sonatype-nexus-snapshots</id>
<name>Sonatype Nexus Snapshots</name>
<url>https://oss.sonatype.org/content/repositories/snapshots/</url>
</snapshotRepository>
<repository>
<id>sonatype-nexus-staging</id>
<name>Nexus Release Repository</name>
<url>http://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
</repository>
</distributionManagement>
<organization>
<name>Google, Inc.</name>
<url>http://www.google.com</url>
</organization>
<dependencies>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>3.8.2</version>
<scope>test</scope>
</dependency>
</dependencies>
<modules> <modules>
<module>gson</module> <module>gson</module>
</modules> </modules>
<profiles>
<!-- Activate PGP signing only when performing a release --> <properties>
<profile> <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<id>release-sign-artifacts</id> <java.version>1.7</java.version>
<activation> </properties>
<property>
<name>performRelease</name> <scm>
<value>true</value> <url>https://github.com/google/gson/</url>
</property> <connection>scm:git:https://github.com/google/gson.git</connection>
</activation> <developerConnection>scm:git:git@github.com:google/gson.git</developerConnection>
<build> <tag>HEAD</tag>
<plugins> </scm>
<plugin>
<groupId>org.apache.maven.plugins</groupId> <issueManagement>
<artifactId>maven-gpg-plugin</artifactId> <system>GitHub Issues</system>
<version>1.5</version> <url>https://github.com/google/gson/issues</url>
<executions> </issueManagement>
<execution>
<id>sign-artifacts</id> <licenses>
<phase>verify</phase> <license>
<goals> <name>Apache 2.0</name>
<goal>sign</goal> <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
</goals> </license>
</execution> </licenses>
</executions>
</plugin> <dependencyManagement>
</plugins> <dependencies>
</build> <dependency>
</profile> <groupId>junit</groupId>
<profile> <artifactId>junit</artifactId>
<id>doclint-java8-disable</id> <version>3.8.2</version>
<activation> <scope>test</scope>
<jdk>[1.8,)</jdk> </dependency>
</activation> </dependencies>
<build> </dependencyManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<configuration>
<additionalparam>-Xdoclint:none</additionalparam>
</configuration>
</plugin>
</plugins>
</build>
</profile>
</profiles>
<build> <build>
<defaultGoal>package</defaultGoal> <pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.0</version>
<configuration>
<source>${java.version}</source>
<target>${java.version}</target>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<version>2.10.3</version>
</plugin>
</plugins>
</pluginManagement>
<plugins> <plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.3</version>
<configuration>
<source>1.5</source>
<target>1.5</target>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<version>2.6</version>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>jar</goal>
</goals>
</execution>
</executions>
<configuration>
<archive>
<addMavenDescriptor>false</addMavenDescriptor>
<manifestEntries>
<Bundle-RequiredExecutionEnvironment>J2SE-1.5, JavaSE-1.6, JavaSE-1.7, JavaSE-1.8</Bundle-RequiredExecutionEnvironment>
<Export-Package><![CDATA[com.google.gson;version=${project.version}, com.google.gson.annotations;version=${project.version}, com.google.gson.reflect;version=${project.version}, com.google.gson.stream;version=${project.version}, com.google.gson.internal;version=${project.version}, com.google.gson.internal.bind;version=${project.version}]]></Export-Package>
<Bundle-Version>${project.version}</Bundle-Version>
<Bundle-ContactAddress>https://github.com/google/gson</Bundle-ContactAddress>
<Bundle-Vendor>Google Gson Project</Bundle-Vendor>
<Bundle-Name>${project.name}</Bundle-Name>
<Bundle-Description>${project.description}</Bundle-Description>
<Bundle-ClassPath>.</Bundle-ClassPath>
<Bundle-ManifestVersion>2</Bundle-ManifestVersion>
<Bundle-SymbolicName>com.google.gson</Bundle-SymbolicName>
</manifestEntries>
</archive>
</configuration>
</plugin>
<plugin>
<!-- TODO(inder): add manifest entry for maven group, artifact, and classifier ids -->
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-source-plugin</artifactId>
<version>2.4</version>
<executions>
<execution>
<id>attach-sources</id>
<phase>verify</phase>
<goals>
<goal>jar</goal>
</goals>
</execution>
</executions>
<configuration>
<archive>
<manifestEntries>
<Eclipse-SourceBundle>com.google.gson;version="${project.version}"</Eclipse-SourceBundle>
<Bundle-SymbolicName>com.google.gson.source</Bundle-SymbolicName>
<Bundle-ManifestVersion>2</Bundle-ManifestVersion>
<Bundle-Version>${project.version}</Bundle-Version>
</manifestEntries>
</archive>
</configuration>
</plugin>
<plugin>
<!-- TODO(inder): add manifest entry for maven group, artifact, and classifier ids -->
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<version>2.10.3</version>
<executions>
<execution>
<id>attach-javadocs</id>
<goals>
<goal>jar</goal>
</goals>
</execution>
</executions>
<configuration>
<includePackageNames>com.google.gson</includePackageNames>
<excludePackageNames>com.google.gson.internal:com.google.gson.internal.bind</excludePackageNames>
<links>
<link>http://docs.oracle.com/javase/1.5.0/docs/api/</link>
</links>
<version>true</version>
<show>protected</show>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-eclipse-plugin</artifactId>
<version>2.10</version>
<configuration>
<downloadSources>true</downloadSources>
<downloadJavadocs>true</downloadJavadocs>
<workspace>
../eclipse-ws/
</workspace>
<workspaceCodeStylesURL>
file:///${basedir}/../lib/gson-formatting-styles.xml
</workspaceCodeStylesURL>
</configuration>
</plugin>
<plugin> <plugin>
<groupId>org.apache.maven.plugins</groupId> <groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-release-plugin</artifactId> <artifactId>maven-release-plugin</artifactId>
<!-- version>2.5</version --> <version>2.4.2</version>
<dependencies>
<dependency>
<groupId>org.apache.maven.scm</groupId>
<artifactId>maven-scm-provider-gitexe</artifactId>
<version>1.9</version>
</dependency>
</dependencies>
<configuration> <configuration>
<arguments>-DenableCiProfile=true</arguments> <autoVersionSubmodules>true</autoVersionSubmodules>
</configuration>
</plugin>
<plugin>
<artifactId>maven-assembly-plugin</artifactId>
<version>2.5.5</version>
<configuration>
<descriptor>assembly-descriptor.xml</descriptor>
<finalName>google-gson-${project.version}</finalName>
<outputDirectory>target/dist</outputDirectory>
<workDirectory>target/assembly/work</workDirectory>
</configuration> </configuration>
</plugin> </plugin>
</plugins> </plugins>
</build> </build>
<developers>
<developer>
<name>Inderjeet Singh</name>
</developer>
<developer>
<name>Joel Leitch</name>
<organization>Google Inc.</organization>
</developer>
<developer>
<name>Jesse Wilson</name>
<organization>Square Inc.</organization>
</developer>
</developers>
</project> </project>