<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>org.sonatype.oss</groupId>
        <artifactId>oss-parent</artifactId>
        <version>5</version>
    </parent>

    <groupId>com.legsem.legstar</groupId>
    <artifactId>legstar-cob2xsd</artifactId>
    <version>0.3.3</version>
    <packaging>jar</packaging>

    <name>LegStar COBOL to XML schema translator</name>
    <description>Translates COBOL structure to XML Schema translator</description>
    <url>http://code.google.com/p/legstar-cob2xsd</url>

    <properties>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <legstarVersion>1.5.1</legstarVersion>
        <antlrVersion>3.2</antlrVersion>
        <antInternalVersion>1.7.0</antInternalVersion> <!-- Used for legstar builds and tests -->
        <antVersion>1.6.5</antVersion>  <!-- Expected to be provided at runtime -->
        <maven.build.timestamp.format>yyyyMMdd-HHmm</maven.build.timestamp.format>
        <buildDate>${maven.build.timestamp}</buildDate>
    </properties>

    <issueManagement>
        <system>Google Code Issue Tracking</system>
        <url>http://code.google.com/p/legstar-cob2xsd/issues/list</url>
    </issueManagement>

    <scm>
        <connection>scm:svn:http://legstar-cob2xsd.googlecode.com/svn/tags/legstar-cob2xsd-0.3.3</connection>
        <developerConnection>scm:svn:https://legstar-cob2xsd.googlecode.com/svn/tags/legstar-cob2xsd-0.3.3</developerConnection>
        <url>http://legstar-cob2xsd.googlecode.com/svn/tags/legstar-cob2xsd-0.3.3</url>
    </scm>

    <distributionManagement>

        <site>
            <id>local.website</id>
            <name>Local Website</name>
            <url>file:///${legstar-dev-website-local-dir}/legstar-cob2xsd</url>
        </site>

    </distributionManagement>

    <mailingLists>
        <mailingList>
            <name>LegStar users mailing list</name>
            <subscribe>http://groups.google.com/group/legstar-user/subscribe</subscribe>
            <unsubscribe>http://groups.google.com/group/legstar-user/subscribe</unsubscribe>
            <post>legstar-user@googlegroups.com</post>
            <archive>http://groups.google.com/group/legstar-user/topics</archive>
        </mailingList>
        <mailingList>
            <name>LegStar dev mailing list</name>
            <subscribe>http://groups.google.com/group/legstar-dev/subscribe</subscribe>
            <unsubscribe>http://groups.google.com/group/legstar-dev/subscribe</unsubscribe>
            <post>legstar-dev@googlegroups.com</post>
            <archive>http://groups.google.com/group/legstar-dev/topics</archive>
        </mailingList>
    </mailingLists>

    <developers>
        <developer>
            <id>fady</id>
            <name>Fady Moussallam</name>
            <email>fady@NOSPAMlegsem.com</email>
            <organization>Legsem.com</organization>
            <roles>
                <role>Project Manager</role>
                <role>Architect</role>
            </roles>
            <timezone>+1</timezone>
        </developer>
    </developers>

    <licenses>
        <license>
            <name>GNU Lesser General Public License</name>
            <url>http://www.gnu.org/licenses/lgpl-2.1.txt</url>
            <distribution>repo</distribution>
        </license>
    </licenses>

    <organization>
        <name>LegSem</name>
        <url>http://www.legsem.com/</url>
    </organization>

    <build>

        <!-- Filter version properties file -->
        <resources>
            <resource>
                <directory>src/main/resources</directory>
                <filtering>true</filtering>
                <includes>
                    <include>**/*.properties</include>
                </includes>
            </resource>
            <resource>
                <directory>src/main/resources</directory>
                <excludes>
                    <exclude>**/*.properties</exclude>
                </excludes>
            </resource>
        </resources>

         <extensions>
            <extension>
                <groupId>org.apache.maven.wagon</groupId>
                <artifactId>wagon-ftp</artifactId>
                <version>1.0-beta-2</version>
            </extension>
            <extension>
                <groupId>org.apache.maven.wagon</groupId>
                <artifactId>wagon-webdav</artifactId>
                <version>1.0-beta-2</version>
            </extension>
        </extensions>

        <plugins>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-release-plugin</artifactId>
                <version>2.0-beta-9</version>
                <configuration>
                    <autoVersionSubmodules>true</autoVersionSubmodules>
                </configuration>
            </plugin>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-site-plugin</artifactId>
                <version>2.2</version>
            </plugin>

            <plugin>
                <artifactId>maven-compiler-plugin</artifactId>
                <configuration>
                    <source>1.5</source>
                    <target>1.5</target>
                </configuration>
            </plugin>

            <plugin>
                <artifactId>maven-antrun-plugin</artifactId>
                <version>1.1</version>

                <executions>

                    <!-- Test the distribution files -->
                    <execution>
                        <id>test-distribution</id>
                        <phase>verify</phase>
                        <configuration>
                            <tasks>
                                <ant antfile="${basedir}/src/main/ant/test-distribution.xml" />
                            </tasks>
                        </configuration>
                        <goals>
                            <goal>run</goal>
                        </goals>
                    </execution>

                </executions>
            </plugin>

            <plugin>
                <groupId>org.antlr</groupId>
                <artifactId>antlr3-maven-plugin</artifactId>
                <version>3.1.3-1</version>
                <configuration>
                    <verbose>true</verbose>
                    <report>false</report>
                    <dfa>false</dfa>
                    <libDirectory>target/generated-sources/antlr3/com/legstar/cob2xsd</libDirectory>
                </configuration>
                <executions>
                    <execution>
                        <id>parser</id>
                        <phase>generate-sources</phase>
                        <goals>
                            <goal>antlr</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>

            <plugin>
                <artifactId>maven-source-plugin</artifactId>
                <executions>
                    <execution>
                        <phase>package</phase>
                        <goals>
                            <goal>jar</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>

            <!-- Produce javadoc jar for each module -->
            <plugin>
                <artifactId>maven-javadoc-plugin</artifactId>
                <executions>
                    <execution>
                        <phase>package</phase>
                        <goals>
                            <goal>jar</goal>
                        </goals>
                    </execution>
                </executions>
                <configuration>
                    <links>
                        <link>http://download.oracle.com/javaee/1.5/api/</link>
                        <link>http://download.oracle.com/javase/1.5.0/docs/api/</link>
                    </links>
                </configuration>
            </plugin>

            <!-- Sign all artifacts -->
            <plugin>
                <artifactId>maven-gpg-plugin</artifactId>
                <executions>
                    <execution>
                        <phase>verify</phase>
                        <goals>
                            <goal>sign</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-jar-plugin</artifactId>
                <executions>
                <!--
                    JAR with test classifier for use by other projects who need COBOL and XML SChema samples
                  -->
                    <execution>
                        <id>bundle-test-jar</id>
                        <phase>package</phase>
                        <goals>
                            <goal>jar</goal>
                        </goals>
                        <configuration>
                            <classifier>test</classifier>
                            <classesDirectory>${project.build.directory}/test-classes</classesDirectory>
                            <includes>
                                <include>cobol/**</include>
                                <include>schema/**</include>
                                <include>xslt/**</include>
                            </includes>
                        </configuration>
                    </execution>

                    <!--
                        Executable jar
                      -->
                   <execution>
                        <id>bundle-exe-jar</id>
                        <phase>package</phase>
                        <goals>
                            <goal>jar</goal>
                        </goals>
                        <configuration>
                            <classifier>exe</classifier>
                            <archive>
                                <manifest>
                                    <addClasspath>true</addClasspath>
                                    <classpathPrefix>lib/</classpathPrefix>
                                    <mainClass>com.legstar.cob2xsd.exe.CobolStructureToXsdMain</mainClass>
                                </manifest>
                            </archive>
                        </configuration>
                    </execution>

                </executions>
            </plugin>

            <plugin>
                <artifactId>maven-dependency-plugin</artifactId>
                <executions>
                    <!-- 
                       Dependencies are useful for ANT scripts classpath and distribution.
                      -->
                    <execution>
                        <id>copy-dependencies</id>
                        <phase>generate-test-resources</phase>
                        <goals>
                            <goal>copy-dependencies</goal>
                        </goals>
                        <configuration>
                            <includeScope>runtime</includeScope>
                            <excludeGroupIds>org.codehaus.jackson</excludeGroupIds>
                        </configuration>
                    </execution>

                </executions>
            </plugin>

            <plugin>
                <artifactId>maven-assembly-plugin</artifactId>
                <version>2.2-beta-5</version>
                <executions>

                <!--
                    Main ZIP distribution (includes executable jar)
                  -->
                    <execution>
                        <id>make-full-assembly</id>
                        <phase>package</phase>
                        <goals>
                            <goal>attached</goal>
                        </goals>
                        <configuration>
                            <descriptors>
                                <descriptor>assembly-full.xml</descriptor>
                            </descriptors>
                            <archiverConfig>
                                <duplicateBehavior>skip</duplicateBehavior>
                            </archiverConfig>
                        </configuration>
                    </execution>

                    <!--
                        Full jar which contains dependencies
                      -->
                    <execution>
                        <id>make-assembly</id>
                        <phase>package</phase>
                        <goals>
                            <goal>attached</goal>
                        </goals>
                        <configuration>
                            <descriptors>
                                <descriptor>assembly.xml</descriptor>
                            </descriptors>
                            <archiverConfig>
                                <duplicateBehavior>skip</duplicateBehavior>
                            </archiverConfig>
                        </configuration>
                    </execution>
                 </executions>
            </plugin>
         </plugins>
   </build>

    <dependencies>

        <!-- ANTLR -->
        <dependency>
            <groupId>org.antlr</groupId>
            <artifactId>antlr</artifactId>
            <version>${antlrVersion}</version>
        </dependency>
        <dependency>
            <groupId>org.antlr</groupId>
            <artifactId>antlr-runtime</artifactId>
            <version>${antlrVersion}</version>
        </dependency>

        <!-- Apache ANT -->
        <dependency>
            <groupId>ant</groupId>
            <artifactId>ant</artifactId>
            <version>${antVersion}</version>
            <scope>provided</scope>
        </dependency>

        <!-- Apache ANT launcher (Used to test generated ANT scripts) -->
        <dependency>
            <groupId>ant</groupId>
            <artifactId>ant-launcher</artifactId>
            <version>${antVersion}</version>
            <scope>test</scope>
        </dependency>

        <!-- Apache Logging API -->
        <dependency>
            <groupId>commons-logging</groupId>
            <artifactId>commons-logging</artifactId>
            <version>1.1</version>
            <exclusions>
                <exclusion>
                    <groupId>logkit</groupId>
                    <artifactId>logkit</artifactId>
                </exclusion>
                <exclusion>
                    <groupId>avalon-framework</groupId>
                    <artifactId>avalon-framework</artifactId>
                </exclusion>
                <exclusion>
                    <groupId>javax.servlet</groupId>
                    <artifactId>servlet-api</artifactId>
                </exclusion>
            </exclusions>
        </dependency>

        <!-- Apache commons IO -->
        <dependency>
            <groupId>commons-io</groupId>
            <artifactId>commons-io</artifactId>
            <version>1.4</version>
        </dependency>

        <!-- Apache commons client -->
        <dependency>
            <groupId>commons-cli</groupId>
            <artifactId>commons-cli</artifactId>
            <version>1.1</version>
        </dependency>

        <!-- Apache XML schema -->
        <dependency>
            <groupId>org.apache.ws.commons.schema</groupId>
            <artifactId>XmlSchema</artifactId>
            <version>1.4.7</version>
        </dependency>

        <!-- LegStar COBOL binding API -->
        <dependency>
            <groupId>com.legsem.legstar</groupId>
            <artifactId>legstar-coxbapi</artifactId>
            <version>${legstarVersion}</version>
        </dependency>

        <!-- LegStar Code Generation API -->
        <dependency>
            <groupId>com.legsem.legstar</groupId>
            <artifactId>legstar-codegen</artifactId>
            <version>${legstarVersion}</version>
        </dependency>

        <!-- Tests -->
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>3.8.1</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>xmlunit</groupId>
            <artifactId>xmlunit</artifactId>
            <version>1.1</version>
            <scope>test</scope>
        </dependency>
    </dependencies>

    <reporting>
        <plugins>

            <plugin>
                <artifactId>maven-project-info-reports-plugin</artifactId>
                <reportSets>
                    <reportSet>
                        <reports>
                            <report>index</report>
                            <report>summary</report>
                            <report>project-team</report>
                            <report>scm</report>
                            <report>issue-tracking</report>
                            <report>mailing-list</report>
                            <report>dependencies</report>
                            <report>license</report>
                        </reports>
                    </reportSet>
                </reportSets>
            </plugin>

            <!-- Aggregate the sources cross references for all modules -->
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-jxr-plugin</artifactId>
                <reportSets>
                    <reportSet>
                        <reports>
                            <report>jxr</report>
                        </reports>
                    </reportSet>
                </reportSets>
            </plugin>

            <!-- Javadoc for all modules -->
            <plugin>
                <artifactId>maven-javadoc-plugin</artifactId>
                <configuration>
                    <links>
                        <link>http://download.oracle.com/javaee/1.5/api/</link>
                        <link>http://download.oracle.com/javase/1.5.0/docs/api/</link>
                    </links>
                </configuration>
                <reportSets>
                    <reportSet>
                        <reports>
                            <report>javadoc</report>
                        </reports>
                    </reportSet>
                </reportSets>
            </plugin>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-pmd-plugin</artifactId>
                <configuration>
                    <targetJdk>1.5</targetJdk>
                </configuration>
            </plugin>

            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>cobertura-maven-plugin</artifactId>
                <version>2.4</version> 
                <configuration>
                    <instrumentation>
                        <!-- Instrumenting performance tests is useless for test coverage analysis -->
                        <excludes>
                            <exclude>**/perf/**/*.class</exclude>
                        </excludes>
                    </instrumentation>
                </configuration>
            </plugin>

            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>taglist-maven-plugin</artifactId>
                <configuration>
                    <tags>
                        <tag>TODO</tag>
                        <tag>@todo</tag>
                        <tag>FIXME</tag>
                        <tag>@fixme</tag>
                        <tag>@deprecated</tag>
                    </tags>
                </configuration>
            </plugin>

            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>findbugs-maven-plugin</artifactId>
            </plugin>

        </plugins>

    </reporting>

</project>