
This way the documentation for that release is embedded within the WAR and can be served directly from the servlet container that is running Gerrit Code Review itself. This should make it easier to look up the relevant information from a running installation. The documentation menu is only installed in the UI if the server has the "Documentation/" subdirectory within the servlet context. This should be true if the server was packaged with our release script, but otherwise would be false as its not there. Its probably more GWT-ey to use some sort of build parameter in the module definition to enable or disable this menu creation code at compile time, allowing GWT to strip out the resources and JavaScript if the documentation wasn't available at build time. But this is far too complex for our needs. The documentation is most likely going to be present, and its only a handful of bytes for the strings. Any minor savings resulting from being able to strip this code out just isn't worth the additional code complexity. Change-Id: Ib2be63cf99fa20ff427ab811ab25d5e9e8a6b21f Signed-off-by: Shawn O. Pearce <sop@google.com>
206 lines
6.3 KiB
XML
206 lines
6.3 KiB
XML
<?xml version="1.0" encoding="UTF-8"?>
|
|
<!--
|
|
Copyright (C) 2009 The Android Open Source Project
|
|
|
|
Licensed under the Apache License, Version 2.0 (the "License");
|
|
you may not use this file except in compliance with the License.
|
|
You may obtain a copy of the License at
|
|
|
|
http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
Unless required by applicable law or agreed to in writing, software
|
|
distributed under the License is distributed on an "AS IS" BASIS,
|
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
See the License for the specific language governing permissions and
|
|
limitations under the License.
|
|
-->
|
|
<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>
|
|
|
|
<parent>
|
|
<groupId>com.google.gerrit</groupId>
|
|
<artifactId>gerrit-parent</artifactId>
|
|
<version>2.1-SNAPSHOT</version>
|
|
</parent>
|
|
|
|
<artifactId>gerrit-war</artifactId>
|
|
<name>Gerrit Code Review - WAR</name>
|
|
<packaging>war</packaging>
|
|
|
|
<description>
|
|
Gerrit packaged as a standard web application archive
|
|
</description>
|
|
|
|
<dependencies>
|
|
<dependency>
|
|
<groupId>javax.servlet</groupId>
|
|
<artifactId>servlet-api</artifactId>
|
|
<!-- compile, not provided. our embedded Jetty needs this -->
|
|
<scope>compile</scope>
|
|
</dependency>
|
|
|
|
<dependency>
|
|
<groupId>com.google.gerrit</groupId>
|
|
<artifactId>gerrit-gwtui</artifactId>
|
|
<version>${project.version}</version>
|
|
<type>war</type>
|
|
<scope>runtime</scope>
|
|
</dependency>
|
|
|
|
<dependency>
|
|
<groupId>com.google.gerrit</groupId>
|
|
<artifactId>gerrit-main</artifactId>
|
|
<version>${project.version}</version>
|
|
<scope>provided</scope>
|
|
</dependency>
|
|
|
|
<dependency>
|
|
<groupId>bouncycastle</groupId>
|
|
<artifactId>bcprov-jdk15</artifactId>
|
|
<version>140</version>
|
|
<scope>provided</scope>
|
|
</dependency>
|
|
|
|
<dependency>
|
|
<groupId>bouncycastle</groupId>
|
|
<artifactId>bcpg-jdk15</artifactId>
|
|
<version>140</version>
|
|
<scope>provided</scope>
|
|
</dependency>
|
|
|
|
<dependency>
|
|
<groupId>org.slf4j</groupId>
|
|
<artifactId>slf4j-log4j12</artifactId>
|
|
</dependency>
|
|
|
|
<dependency>
|
|
<groupId>log4j</groupId>
|
|
<artifactId>log4j</artifactId>
|
|
</dependency>
|
|
|
|
<dependency>
|
|
<groupId>com.google.gerrit</groupId>
|
|
<artifactId>gerrit-sshd</artifactId>
|
|
<version>${project.version}</version>
|
|
</dependency>
|
|
|
|
<dependency>
|
|
<groupId>com.google.gerrit</groupId>
|
|
<artifactId>gerrit-httpd</artifactId>
|
|
<version>${project.version}</version>
|
|
</dependency>
|
|
|
|
<dependency>
|
|
<groupId>com.google.gerrit</groupId>
|
|
<artifactId>gerrit-pgm</artifactId>
|
|
<version>${project.version}</version>
|
|
</dependency>
|
|
</dependencies>
|
|
|
|
<profiles>
|
|
<profile>
|
|
<id>include-documentation-profile</id>
|
|
<activation>
|
|
<property>
|
|
<name>gerrit.include-documentation</name>
|
|
</property>
|
|
</activation>
|
|
<build>
|
|
<plugins>
|
|
<plugin>
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
<artifactId>maven-antrun-plugin</artifactId>
|
|
<executions>
|
|
<execution>
|
|
<id>include-documentation</id>
|
|
<phase>process-classes</phase>
|
|
<configuration>
|
|
<tasks>
|
|
<property name="src" location="${basedir}/../Documentation" />
|
|
<property name="out" location="${project.build.directory}/${project.build.finalName}" />
|
|
<property name="dst" location="${out}/Documentation" />
|
|
|
|
<exec dir="${src}" executable="make">
|
|
<arg value="VERSION=${project.version}" />
|
|
<arg value="clean" />
|
|
<arg value="all" />
|
|
</exec>
|
|
|
|
<mkdir dir="${dst}" />
|
|
<copy overwrite="true" todir="${dst}">
|
|
<fileset dir="${src}">
|
|
<include name="*.html" />
|
|
</fileset>
|
|
</copy>
|
|
</tasks>
|
|
</configuration>
|
|
<goals>
|
|
<goal>run</goal>
|
|
</goals>
|
|
</execution>
|
|
</executions>
|
|
</plugin>
|
|
</plugins>
|
|
</build>
|
|
</profile>
|
|
</profiles>
|
|
|
|
<build>
|
|
<plugins>
|
|
<plugin>
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
<artifactId>maven-war-plugin</artifactId>
|
|
<configuration>
|
|
<warName>gerrit-${project.version}</warName>
|
|
<archiveClasses>true</archiveClasses>
|
|
<archive>
|
|
<addMavenDescriptor>false</addMavenDescriptor>
|
|
<manifestEntries>
|
|
<Main-Class>Main</Main-Class>
|
|
<Implementation-Title>Gerrit Code Review</Implementation-Title>
|
|
<Implementation-Version>${project.version}</Implementation-Version>
|
|
</manifestEntries>
|
|
</archive>
|
|
<overlays>
|
|
<overlay>
|
|
<groupId>com.google.gerrit</groupId>
|
|
<artifactId>gerrit-main</artifactId>
|
|
<type>jar</type>
|
|
<includes>
|
|
<include>Main.class</include>
|
|
<include>com/google/gerrit/launcher/*.class</include>
|
|
</includes>
|
|
</overlay>
|
|
</overlays>
|
|
</configuration>
|
|
</plugin>
|
|
|
|
<plugin>
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
<artifactId>maven-antrun-plugin</artifactId>
|
|
<executions>
|
|
<execution>
|
|
<id>fix-output</id>
|
|
<phase>process-classes</phase>
|
|
<configuration>
|
|
<tasks>
|
|
<property name="src" location="${basedir}/../Documentation" />
|
|
<property name="dst" location="${project.build.directory}/${project.build.finalName}" />
|
|
|
|
<copy tofile="${dst}/LICENSES.txt"
|
|
file="${src}/licenses.txt"
|
|
overwrite="true" />
|
|
</tasks>
|
|
</configuration>
|
|
<goals>
|
|
<goal>run</goal>
|
|
</goals>
|
|
</execution>
|
|
</executions>
|
|
</plugin>
|
|
</plugins>
|
|
</build>
|
|
</project>
|