Add commit command to the pgm package
[jgit.git] / org.eclipse.jgit.pgm / pom.xml
bloba42e4e72233a791257859ce9ec33f76375a802cf
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!--
3    Copyright (C) 2009-2010, Google Inc.
4    and other copyright owners as documented in the project's IP log.
6    This program and the accompanying materials are made available
7    under the terms of the Eclipse Distribution License v1.0 which
8    accompanies this distribution, is reproduced below, and is
9    available at http://www.eclipse.org/org/documents/edl-v10.php
11    All rights reserved.
13    Redistribution and use in source and binary forms, with or
14    without modification, are permitted provided that the following
15    conditions are met:
17    - Redistributions of source code must retain the above copyright
18      notice, this list of conditions and the following disclaimer.
20    - Redistributions in binary form must reproduce the above
21      copyright notice, this list of conditions and the following
22      disclaimer in the documentation and/or other materials provided
23      with the distribution.
25    - Neither the name of the Eclipse Foundation, Inc. nor the
26      names of its contributors may be used to endorse or promote
27      products derived from this software without specific prior
28      written permission.
30    THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
31    CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
32    INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
33    OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
34    ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
35    CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
36    SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
37    NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
38    LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
39    CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
40    STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
41    ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
42    ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
43 -->
45 <project xmlns="http://maven.apache.org/POM/4.0.0"
46     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
47     xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
48   <modelVersion>4.0.0</modelVersion>
50   <parent>
51     <groupId>org.eclipse.jgit</groupId>
52     <artifactId>org.eclipse.jgit-parent</artifactId>
53     <version>0.8.0-SNAPSHOT</version>
54   </parent>
56   <artifactId>org.eclipse.jgit.pgm</artifactId>
57   <name>JGit - Command Line Interface</name>
59   <description>
60     Command line client tools built on top of JGit.
61   </description>
63   <dependencies>
64     <dependency>
65       <groupId>args4j</groupId>
66       <artifactId>args4j</artifactId>
67     </dependency>
69     <dependency>
70       <groupId>org.eclipse.jgit</groupId>
71       <artifactId>org.eclipse.jgit</artifactId>
72       <version>${project.version}</version>
73     </dependency>
75     <dependency>
76       <groupId>org.eclipse.jgit</groupId>
77       <artifactId>org.eclipse.jgit.iplog</artifactId>
78       <version>${project.version}</version>
79     </dependency>
81     <dependency>
82       <groupId>org.eclipse.jgit</groupId>
83       <artifactId>org.eclipse.jgit.ui</artifactId>
84       <version>${project.version}</version>
85     </dependency>
86   </dependencies>
88   <profiles>
89     <profile>
90       <id>java6</id>
91       <activation>
92         <activeByDefault>true</activeByDefault>
93       </activation>
94       <dependencies>
95         <dependency>
96           <groupId>org.eclipse.jgit</groupId>
97           <artifactId>org.eclipse.jgit.console</artifactId>
98           <version>${project.version}</version>
99         </dependency>
100       </dependencies>
101     </profile>
102   </profiles>
104   <build>
105     <sourceDirectory>src/</sourceDirectory>
107     <resources>
108       <resource>
109         <directory>.</directory>
110         <includes>
111           <include>META-INF/services/org.eclipse.jgit.pgm.TextBuiltin</include>
112         </includes>
113       </resource>
114     </resources>
116     <plugins>
117       <plugin>
118         <groupId>org.apache.maven.plugins</groupId>
119         <artifactId>maven-shade-plugin</artifactId>
120         <executions>
121           <execution>
122             <phase>package</phase>
123             <goals>
124               <goal>shade</goal>
125             </goals>
126             <configuration>
127               <finalName>jgit-cli</finalName>
128               <createDependencyReducedPom>false</createDependencyReducedPom>
129               <transformers>
130                 <transformer implementation="org.apache.maven.plugins.shade.resource.ServicesResourceTransformer" />
131                 <transformer implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
132                   <manifestEntries>
133                     <Main-Class>org.eclipse.jgit.pgm.Main</Main-Class>
134                     <Implementation-Title>JGit Command Line Interface</Implementation-Title>
135                   </manifestEntries>
136                 </transformer>
137               </transformers>
138             </configuration>
139           </execution>
140         </executions>
141       </plugin>
143       <plugin>
144         <groupId>org.apache.maven.plugins</groupId>
145         <artifactId>maven-antrun-plugin</artifactId>
146         <executions>
147           <execution>
148             <id>create_jgit</id>
149             <phase>package</phase>
150             <configuration>
151               <tasks>
152                 <concat destfile="${basedir}/target/jgit" force="yes" binary="true">
153                   <fileset file="${basedir}/jgit.sh" />
154                   <fileset file="${basedir}/target/jgit-cli.jar" />
155                 </concat>
156                 <chmod file="${basedir}/target/jgit" perm="a+x"/>
157               </tasks>
158             </configuration>
159             <goals>
160               <goal>run</goal>
161             </goals>
162           </execution>
163         </executions>
164       </plugin>
166       <plugin>
167         <groupId>org.codehaus.mojo</groupId>
168         <artifactId>build-helper-maven-plugin</artifactId>
169         <executions>
170           <execution>
171             <id>attach_jgit</id>
172             <phase>package</phase>
173             <goals>
174               <goal>attach-artifact</goal>
175             </goals>
176             <configuration>
177               <artifacts>
178                 <artifact>
179                   <file>${basedir}/target/jgit</file>
180                   <type>sh</type>
181                 </artifact>
182               </artifacts>
183             </configuration>
184           </execution>
185         </executions>
186       </plugin>
187     </plugins>
188   </build>
189 </project>