diff options
author | Edwin Kempin <edwin.kempin@sap.com> | 2013-10-05 11:24:30 +0200 |
---|---|---|
committer | Edwin Kempin <edwin.kempin@sap.com> | 2013-10-05 11:24:30 +0200 |
commit | 62f5438bdb86052bef43c59011422759f257a236 (patch) | |
tree | c32c9b4f43d2470e68cf6dfeba78e9990b22f022 | |
parent | ef48818083df6659aad02a0898826f3c404ee189 (diff) |
Generate javadoc for gerrit extension and plugin API
To make the consumption of the gerrit extension and plugin API easier
for plugin developers gerrit-extension-api.jar and
gerrit-plugin-api.jar should be published to Maven central. For this
having javadocs generated is required.
Change-Id: Ibb13fbb61c94c76fe6e2f7041d5a1e269d39d788
Signed-off-by: Edwin Kempin <edwin.kempin@sap.com>
-rw-r--r-- | gerrit-extension-api/pom.xml | 43 | ||||
-rw-r--r-- | gerrit-plugin-api/pom.xml | 44 | ||||
-rw-r--r-- | pom.xml | 6 | ||||
-rwxr-xr-x | tools/deploy_api.sh | 21 |
4 files changed, 114 insertions, 0 deletions
diff --git a/gerrit-extension-api/pom.xml b/gerrit-extension-api/pom.xml index d641a3be3b..4c8d8deb4b 100644 --- a/gerrit-extension-api/pom.xml +++ b/gerrit-extension-api/pom.xml @@ -81,6 +81,49 @@ limitations under the License. </execution> </executions> </plugin> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-dependency-plugin</artifactId> + <executions> + <execution> + <id>unpack-artifact-sources</id> + <phase>generate-resources</phase> + <goals> + <goal>unpack</goal> + </goals> + <configuration> + <artifactItems> + <artifactItem> + <groupId>${project.groupId}</groupId> + <artifactId>gerrit-extension-api</artifactId> + <version>${project.version}</version> + <classifier>all-sources</classifier> + <overWrite>true</overWrite> + </artifactItem> + </artifactItems> + <outputDirectory>${project.build.directory}/unpack_sources</outputDirectory> + </configuration> + </execution> + </executions> + </plugin> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-javadoc-plugin</artifactId> + <configuration> + <sourcepath>${project.build.directory}/unpack_sources</sourcepath> + <encoding>ISO-8859-1</encoding> + <quiet>true</quiet> + <detectOfflineLinks>false</detectOfflineLinks> + </configuration> + <executions> + <execution> + <goals> + <goal>jar</goal> + </goals> + <phase>process-resources</phase> + </execution> + </executions> + </plugin> </plugins> </build> </project> diff --git a/gerrit-plugin-api/pom.xml b/gerrit-plugin-api/pom.xml index 3190379316..97b4eaa51b 100644 --- a/gerrit-plugin-api/pom.xml +++ b/gerrit-plugin-api/pom.xml @@ -117,6 +117,50 @@ limitations under the License. </execution> </executions> </plugin> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-dependency-plugin</artifactId> + <executions> + <execution> + <id>unpack-artifact-sources</id> + <phase>generate-resources</phase> + <goals> + <goal>unpack</goal> + </goals> + <configuration> + <artifactItems> + <artifactItem> + <groupId>${project.groupId}</groupId> + <artifactId>gerrit-plugin-api</artifactId> + <version>${project.version}</version> + <classifier>sources</classifier> + <overWrite>true</overWrite> + </artifactItem> + </artifactItems> + <outputDirectory>${project.build.directory}/unpack_sources</outputDirectory> + </configuration> + </execution> + </executions> + </plugin> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-javadoc-plugin</artifactId> + <version>2.7</version> + <configuration> + <sourcepath>${project.build.directory}/unpack_sources</sourcepath> + <encoding>ISO-8859-1</encoding> + <quiet>true</quiet> + <detectOfflineLinks>false</detectOfflineLinks> + </configuration> + <executions> + <execution> + <goals> + <goal>jar</goal> + </goals> + <phase>process-resources</phase> + </execution> + </executions> + </plugin> </plugins> </build> </project> @@ -357,6 +357,12 @@ limitations under the License. <plugin> <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-javadoc-plugin</artifactId> + <version>2.9.1</version> + </plugin> + + <plugin> + <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-shade-plugin</artifactId> <version>1.6</version> </plugin> diff --git a/tools/deploy_api.sh b/tools/deploy_api.sh index 26baa31cbb..7d1ff0672a 100755 --- a/tools/deploy_api.sh +++ b/tools/deploy_api.sh @@ -38,6 +38,16 @@ mvn deploy:deploy-file \ -DrepositoryId=gerrit-api-repository \ -Durl=$URL +mvn deploy:deploy-file \ + -DgroupId=com.google.gerrit \ + -DartifactId=gerrit-extension-api \ + -Dversion=$VER \ + -Dpackaging=jar \ + -Dfile=gerrit-extension-api/target/gerrit-extension-api-$VER-javadoc.jar \ + -Djava-source=false \ + -DrepositoryId=gerrit-api-repository \ + -Durl=$URL + echo "Deploying $type gerrit-plugin-api $VER" mvn deploy:deploy-file \ @@ -58,3 +68,14 @@ mvn deploy:deploy-file \ -Djava-source=false \ -DrepositoryId=gerrit-api-repository \ -Durl=$URL + +mvn deploy:deploy-file \ + -DgroupId=com.google.gerrit \ + -DartifactId=gerrit-plugin-api \ + -Dversion=$VER \ + -Dpackaging=jar \ + -Dfile=gerrit-plugin-api/target/gerrit-plugin-api-$VER-javadoc.jar \ + -Djava-source=false \ + -DrepositoryId=gerrit-api-repository \ + -Durl=$URL + |