Files
gerrit/gerrit-plugin-archetype/pom.xml
Sasa Zivkov 844c51ed40 Add maven archetype for creating gerrit plugin projects.
Until now creation of a new Gerrit plugin meant either starting from
scratch or copying and modifying and existing plugin.

This change introduces a maven archetype for creating new Gerrit plugin
projects. Assuming gerrit-plugin-api and gerrit-plugin-archetype are
installed in a maven repository one can create a new Gerrit plugin
project by executing a command like:

  mvn archetype:generate -DarchetypeGroupId=com.google.gerrit \
    -DarchetypeArtifactId=gerrit-plugin-archetype \
    -DarchetypeVersion=2.5-SNAPSHOT \
    -DgroupId=com.google.gerrit \
    -DartifactId=testPlugin

Maven will ask for additional properties and then create the plugin in
the current directory. To change the default property values answer 'n'
when maven asks for confirm properties configuration. It will then ask
again for all properties including those with predefined default values.

A missing part is to not generate [Ssh|Http]Module.java skeletons in
case when user choses 'n' for some of Gerrit-[Ssh|Http]Module
properties.

Change-Id: I0b91957415de85eee029c91a6ac7e27096d6a452
Signed-off-by: Sasa Zivkov <sasa.zivkov@sap.com>
2012-05-31 15:56:59 +02:00

54 lines
1.7 KiB
XML

<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (C) 2012 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.5-SNAPSHOT</version>
</parent>
<artifactId>gerrit-plugin-archetype</artifactId>
<name>Gerrit Code Review - Plugin Archetype</name>
<properties>
<defaultGerritApiVersion>${project.version}</defaultGerritApiVersion>
</properties>
<build>
<resources>
<resource>
<directory>src/main/resources</directory>
<filtering>true</filtering>
<includes>
<include>META-INF/maven/archetype-metadata.xml</include>
</includes>
</resource>
<resource>
<directory>src/main/resources</directory>
<filtering>false</filtering>
<excludes>
<exclude>META-INF/maven/archetype-metadata.xml</exclude>
</excludes>
</resource>
</resources>
</build>
</project>