<?xml version="1.0" encoding="UTF-8"?>
<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>
		<artifactId>maven-parent</artifactId>
		<groupId>org.gcube.tools</groupId>
		<version>1.0.0</version>
		<relativePath />
	</parent>

	<!-- POM file generated with GWT webAppCreator -->
	<modelVersion>4.0.0</modelVersion>
	<groupId>org.gcube.portlets.user.tdtemplate</groupId>
	<artifactId>tabular-data-template</artifactId>
	<packaging>jar</packaging>
	<version>1.8.0-4.8.0-142129</version>
	<name>tabular-data-template</name>
	<description>Tabular Data Template allows the users to create several template type. 
	A table template can be applied to: CODELIST, DATASET, GENERIC</description>

	<properties>
		<distroDirectory>${project.basedir}/distro</distroDirectory>
		<webappDirectory>${project.build.directory}/${project.build.finalName}</webappDirectory>
		<templatesDirectory>templates</templatesDirectory>
		<distroDirectory>distro</distroDirectory>
		<!-- <configDirectory>config</configDirectory> -->

		<!-- Convenience property to set the GWT version -->
		<!-- <gwtVersion>2.5.1</gwtVersion> -->

		<!-- Next -->
		<gwtVersion>2.6.1</gwtVersion>
		<gxt2Version>2.6.1</gxt2Version>

		<!-- To make this work on gwt-run you need to set up global env vars. on 
			MacOSX edit this file /etc/launchd.conf and put "setenv GLOBUS_LOCATION /Users/massi/portal/Portal-Bundle/gCore" 
			on Linux? -->
		<GLOBUS_LOCATION>${env.GLOBUS_LOCATION}</GLOBUS_LOCATION>
		<!-- GWT needs at least java 1.5 -->
		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
		<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
	</properties>

	<scm>
		<connection>scm:svn:http://svn.d4science.research-infrastructures.eu/gcube/trunk/portlets/user/${project.artifactId}</connection>
		<developerConnection>scm:https://svn.d4science.research-infrastructures.eu/gcube/trunk/portlets/user/${project.artifactId}</developerConnection>
		<url>http://svn.d4science.research-infrastructures.eu/gcube/trunk/portlets/user/${project.artifactId}</url>
	</scm>

	<dependencyManagement>
		<dependencies>
			<dependency>
				<groupId>org.gcube.distribution</groupId>
				<artifactId>maven-portal-bom</artifactId>
				<version>3.3.0-4.8.0-144184</version>
				<type>pom</type>
				<scope>import</scope>
			</dependency>
		</dependencies>
	</dependencyManagement>

	<dependencies>
		<dependency>
			<groupId>com.google.gwt</groupId>
			<artifactId>gwt-servlet</artifactId>
			<version>${gwtVersion}</version>
			<scope>provided</scope>
		</dependency>
		<dependency>
			<groupId>com.google.gwt</groupId>
			<artifactId>gwt-user</artifactId>
			<version>${gwtVersion}</version>
			<scope>provided</scope>
		</dependency>
		<dependency>
			<groupId>com.sencha.gxt</groupId>
			<artifactId>gxt2.2.5-gwt2.X</artifactId>
			<version>${gxt2Version}</version>
		</dependency>

		<!-- <dependency> <groupId>com.extjs.gxt</groupId> <artifactId>gxt</artifactId> 
			<version>2.2.5</version> </dependency> -->
		<dependency>
			<groupId>junit</groupId>
			<artifactId>junit</artifactId>
			<version>4.7</version>
			<scope>test</scope>
		</dependency>
		<dependency>
			<groupId>javax.validation</groupId>
			<artifactId>validation-api</artifactId>
			<version>1.0.0.GA</version>
			<scope>test</scope>
		</dependency>

		<dependency>
			<groupId>org.gcube.portlets.user</groupId>
			<artifactId>tabular-data-template-operation</artifactId>
			<version>1.1.0-4.8.0-142127</version>
			<scope>compile</scope>
		</dependency>

		<!-- tabular-data-widget-common-event used by TD-GWT-SERVICE -->
		<dependency>
			<groupId>org.gcube.portlets.user</groupId>
			<artifactId>tabular-data-widget-common-event</artifactId>
			<version>1.11.0-4.8.0-148727</version>
			<scope>provided</scope>
		</dependency>

		<!-- tabular-data-expression-widget used by TD-GWT-SERVICE -->
		<dependency>
			<groupId>org.gcube.portlets.user</groupId>
			<artifactId>tabular-data-expression-widget</artifactId>
			<version>1.10.0-4.8.0-148656</version>
			<scope>provided</scope>
		</dependency>

		<!-- tabular-data-widgetx-tdx-source - used by TD-GWT-SERVICE -->
		<dependency>
			<groupId>org.gcube.portlets.user</groupId>
			<artifactId>tabular-data-widgetx-tdx-source</artifactId>
			<version>1.10.0-4.8.0-142668</version>
			<scope>provided</scope>
		</dependency>

		<dependency>
			<groupId>org.gcube.data.analysis.tabulardata</groupId>
			<artifactId>evaluator-description</artifactId>
			<version>1.2.1-4.8.0-125045</version>
			<scope>compile</scope>
		</dependency>

		<dependency>
			<groupId>javax.validation</groupId>
			<artifactId>validation-api</artifactId>
			<version>1.0.0.GA</version>
			<classifier>sources</classifier>
			<scope>test</scope>
		</dependency>

		<!-- SERVER LOGGERS -->
		<dependency>
			<groupId>org.slf4j</groupId>
			<artifactId>slf4j-api</artifactId>
			<scope>provided</scope>
		</dependency>

		<dependency>
			<groupId>org.slf4j</groupId>
			<artifactId>slf4j-log4j12</artifactId>
			<scope>provided</scope>
		</dependency>

		<dependency>
			<groupId>org.gcube.portlets.user</groupId>
			<artifactId>tabular-data-template-operation</artifactId>
			<version>1.1.0-4.8.0-142127</version>
			<scope>compile</scope>
		</dependency>
		
		<dependency>
			<groupId>org.gcube.data.analysis.tabulardata</groupId>
			<artifactId>service-client-impl</artifactId>
			<version>2.6.1-4.8.0-144782</version>
			<scope>provided</scope>
		</dependency>

		<!-- End Service Dependencies -->

		<dependency>
			<groupId>org.gcube.core</groupId>
			<artifactId>common-scope-maps</artifactId>
			<scope>provided</scope>
		</dependency>

		<dependency>
			<groupId>org.gcube.portal</groupId>
			<artifactId>custom-portal-handler</artifactId>
			<scope>provided</scope>
		</dependency>
		
		<!-- PORTAL MANAGER -->
		<dependency>
			<groupId>org.gcube.common.portal</groupId>
			<artifactId>portal-manager</artifactId>
			<scope>provided</scope>
		</dependency>
		
		<!-- User Management Core  -->
		<dependency>
			<groupId>org.gcube.dvos</groupId>
			<artifactId>usermanagement-core</artifactId>
			<scope>provided</scope>
		</dependency>
		
		<dependency>
			<groupId>org.gcube.portlets.user</groupId>
			<artifactId>tabular-data-column-widget</artifactId>
			<version>1.10.0-4.8.0-142633</version>
			<scope>provided</scope>
		</dependency>

		<!-- tabular-data-gwt-service -->
		<dependency>
			<groupId>org.gcube.portlets.user</groupId>
			<artifactId>tabular-data-gwt-service</artifactId>
			<version>2.18.0-4.8.0-152964</version>
			<scope>provided</scope>
		</dependency>

	</dependencies>

	<build>

		<resources>
			<resource>
				<directory>src/main/java</directory>
				<includes>
					<include>**/*.*</include>
				</includes>
			</resource>
		</resources>

		<!-- Generate compiled stuff in the folder used for developing mode -->
		<outputDirectory>${webappDirectory}/WEB-INF/classes</outputDirectory>

		<plugins>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-surefire-plugin</artifactId>
				<version>2.16</version>
				<configuration>
					<skipTests>true</skipTests>
				</configuration>
				<!-- TODO check if needed -->
				<dependencies>
					<dependency>
						<groupId>org.apache.maven.surefire</groupId>
						<artifactId>surefire-junit47</artifactId>
						<version>2.16</version>
					</dependency>
				</dependencies>
			</plugin>

			<!-- GWT Maven Plugin -->
			<plugin>
				<groupId>org.codehaus.mojo</groupId>
				<artifactId>gwt-maven-plugin</artifactId>
				<version>${gwtVersion}</version>
				<executions>
					<execution>
						<goals>
							<goal>resources</goal>
						</goals>
					</execution>
				</executions>
				<configuration>
					<runTarget>TabularDataTemplate.html</runTarget>
					<hostedWebapp>${webappDirectory}</hostedWebapp>
					<module>org.gcube.portlets.user.tdtemplate.TabularDataTemplate</module>
				</configuration>
			</plugin>

			<!-- Maven -->
			<plugin>
				<artifactId>maven-resources-plugin</artifactId>
				<version>2.6</version>
				<executions>
					<execution>
						<id>copy-distro-resources</id>
						<phase>process-resources</phase>
						<goals>
							<goal>copy-resources</goal>
						</goals>
						<configuration>
							<outputDirectory>${distroDirectory}</outputDirectory>
							<resources>
								<resource>
									<directory>${templatesDirectory}</directory>
									<filtering>true</filtering>
								</resource>
							</resources>
						</configuration>
					</execution>
				</executions>
			</plugin>
			<plugin>
				<artifactId>maven-clean-plugin</artifactId>
				<version>2.5</version>
				<configuration>
					<filesets>
						<fileset>
							<directory>${distroDirectory}</directory>
							<includes>
								<include>**</include>
							</includes>
							<followSymlinks>false</followSymlinks>
						</fileset>
					</filesets>
				</configuration>
			</plugin>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-assembly-plugin</artifactId>
				<version>2.2</version>
				<configuration>
					<descriptors>
						<descriptor>${templatesDirectory}/descriptor.xml</descriptor>
					</descriptors>
				</configuration>
				<executions>
					<execution>
						<id>servicearchive</id>
						<phase>package</phase>
						<goals>
							<goal>single</goal>
						</goals>
					</execution>
				</executions>
			</plugin>


		</plugins>

		<pluginManagement>
			<plugins>
				<!--This plugin's configuration is used to store Eclipse m2e settings 
					only. It has no influence on the Maven build itself. -->
				<plugin>
					<groupId>org.eclipse.m2e</groupId>
					<artifactId>lifecycle-mapping</artifactId>
					<version>1.0.0</version>
					<configuration>
						<lifecycleMappingMetadata>
							<pluginExecutions>
								<pluginExecution>
									<pluginExecutionFilter>
										<groupId>
											org.codehaus.mojo
										</groupId>
										<artifactId>
											gwt-maven-plugin
										</artifactId>
										<versionRange>
											[2.5.1,)
										</versionRange>
										<goals>
											<goal>resources</goal>
										</goals>
									</pluginExecutionFilter>
									<action>
										<ignore></ignore>
									</action>
								</pluginExecution>
							</pluginExecutions>
						</lifecycleMappingMetadata>
					</configuration>
				</plugin>
			</plugins>
		</pluginManagement>
	</build>

</project>
