<?xml version="1.0" encoding="UTF-8"?>
<!--

    Copyright (C) 2009 eXo Platform SAS.

    This is free software; you can redistribute it and/or modify it
    under the terms of the GNU Lesser General Public License as
    published by the Free Software Foundation; either version 2.1 of
    the License, or (at your option) any later version.

    This software is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
    Lesser General Public License for more details.

    You should have received a copy of the GNU Lesser General Public
    License along with this software; if not, write to the Free
    Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
    02110-1301 USA, or see the FSF site: http://www.fsf.org.

-->

<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">
   <parent>
       <groupId>org.exoplatform.kernel</groupId>
       <artifactId>kernel-parent</artifactId>
       <version>2.4.0-GA</version>
       <relativePath>../../pom.xml</relativePath>
   </parent>

   <modelVersion>4.0.0</modelVersion>
   <artifactId>kernel.packaging.module</artifactId>
   <packaging>pom</packaging>
   <name>eXo Kernel Build module</name>
   <description>eXo Kernel Build module</description>

   <properties>
        <exobuild.name>kernel</exobuild.name>
        <exobuild.type>module</exobuild.type>
        <enforcer.skip>true</enforcer.skip>
   </properties>

   <build>
       <plugins>
           <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-resources-plugin</artifactId>
                <executions>
                  <execution>
                    <id>prepare</id>
                    <phase>package</phase>
                    <goals>
                      <goal>copy-resources</goal>
                    </goals>
                    <configuration>
                      <outputDirectory>target</outputDirectory>
                      <resources>
                          <resource>
                            <directory>src/main/javascript</directory>
                            <filtering>true</filtering>
                          </resource>
                      </resources>
                    </configuration>
                  </execution>
                </executions>
           </plugin>
           <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>build-helper-maven-plugin</artifactId>
                <version>1.3</version>
                <executions>
                  <execution>
                    <id>attach-artifacts</id>
                    <phase>package</phase>
                    <goals>
                      <goal>attach-artifact</goal>
                    </goals>
                    <configuration>
                      <artifacts>
                        <artifact>
                          <file>target/${exobuild.name}.packaging.${exobuild.type}.js</file>
                          <type>js</type>
                        </artifact>
                      </artifacts>
                    </configuration>
                  </execution>
                </executions>
            </plugin>
       </plugins>
   </build> 
</project>
