<!-- Copyright (c) 2020-2022 BITPlan GmbH Project details and license at: https://github.com/BITPlan/com.bitplan.wikitask -->
<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/xsd/maven-4.0.0.xsd">
	<modelVersion>4.0.0</modelVersion>
	<parent>
		<groupId>com.bitplan.pom</groupId>
		<artifactId>com.bitplan.pom</artifactId>
		<version>0.0.35</version>
		<relativePath>../com.bitplan.pom/pom.xml</relativePath>
	</parent>
	<groupId>com.bitplan</groupId>
	<artifactId>com.bitplan.wikitask</artifactId>
	<packaging>jar</packaging>
	<name>com.bitplan.wikitask</name>
	<version>0.0.3</version>
	<description>WikiTask Server for Semantic MediaWiki based ProfiWiki page generation</description>
	<url>https://github.com/BITPlan/com.bitplan.wikitask</url>
	<properties>
		<!-- for parent pom to work -->
		<github.project>com.bitplan.wikitask</github.project>
		<!-- for README.md generation -->
		<documentation.wiki>http://wiki.bitplan.com/index.php/com.bitplan.wikitask</documentation.wiki>
		<!-- versions of other libraries to be used -->
		<mediawiki-japi.version>0.2.2</mediawiki-japi.version>
	</properties>
	<dependencies>
		<!-- mediawik-japi -->
		<dependency>
			<groupId>com.bitplan</groupId>
			<artifactId>mediawiki-japi</artifactId>
			<version>${mediawiki-japi.version}</version>
		</dependency>
		<!-- SiDIF triplestore -->
		<dependency>
			<groupId>com.bitplan</groupId>
			<artifactId>org.sidif.triplestore</artifactId>
			<version>0.0.10</version>
		</dependency>
		<dependency>
			<groupId>com.bitplan</groupId>
			<artifactId>org.sidif.triplestore</artifactId>
			<version>0.0.10</version>
			<scope>test</scope>
			<type>test-jar</type>
		</dependency>
		<!-- SSH support
		  https://mvnrepository.com/artifact/com.jcraft/jsch -->
		<dependency>
			<groupId>com.jcraft</groupId>
			<artifactId>jsch</artifactId>
			<version>0.1.55</version>
		</dependency>
		<!-- freemarker template support -->
		<dependency>
			<artifactId>com.bitplan.rest.freemarker</artifactId>
			<groupId>com.bitplan</groupId>
			<version>0.0.1</version>
		</dependency>
		<!-- simplerest -->
		<dependency>
			<groupId>com.bitplan.rest</groupId>
			<artifactId>com.bitplan.simplerest</artifactId>
			<version>0.0.13</version>
		</dependency>
		<!-- simplerest TestRestserver -->
		<dependency>
			<groupId>com.bitplan.rest</groupId>
			<artifactId>com.bitplan.simplerest</artifactId>
			<version>0.0.13</version>
			<type>test-jar</type>
		</dependency>
		<!-- simplerest -api -->
		<dependency>
			<groupId>com.bitplan.rest</groupId>
			<artifactId>com.bitplan.simplerest-api</artifactId>
			<version>0.0.8</version>
		</dependency>
		<!-- rythm template support -->
		<dependency>
			<groupId>org.rythmengine</groupId>
			<artifactId>rythm-engine</artifactId>
			<version>1.2.2</version>
			<exclusions>
				<exclusion>
					<groupId>com.alibaba</groupId>
					<artifactId>fastjson</artifactId>
				</exclusion>
			</exclusions>
		</dependency>
		<!-- https://mvnrepository.com/artifact/com.alibaba/fastjson -->
		<dependency>
			<groupId>com.alibaba</groupId>
			<artifactId>fastjson</artifactId>
			<version>1.2.54</version>
		</dependency>
		<!-- JUnit testing -->
		<dependency>
			<groupId>junit</groupId>
			<artifactId>junit</artifactId>
			<scope>test</scope>
		</dependency>
		<!-- https://mvnrepository.com/artifact/org.hamcrest/hamcrest-all -->
		<dependency>
			<groupId>org.hamcrest</groupId>
			<artifactId>hamcrest-all</artifactId>
		</dependency>
		<!-- https://mvnrepository.com/artifact/mysql/mysql-connector-java -->
		<dependency>
			<groupId>mysql</groupId>
			<artifactId>mysql-connector-java</artifactId>
			<version>5.1.47</version>
		</dependency>
	</dependencies>
	<build>
		<plugins>
			<!-- jar creation -->
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-jar-plugin</artifactId>
				<version>${maven-jar-plugin.version}</version>
				<configuration>
					<archive>
						<manifest>
							<addClasspath>true</addClasspath>
							<mainClass>org.sidif.wiki.rest.WikiTaskServer</mainClass>
						</manifest>
					</archive>
				</configuration>
			</plugin>
			<!-- executable jar with dependencies see http://stackoverflow.com/questions/574594/how-can-i-create-an-executable-jar-with-dependencies-using-maven 
				run with mvn clean compile assembly:single -->
			<plugin>
				<artifactId>maven-assembly-plugin</artifactId>
				<version>${maven-assembly-plugin.version}</version>
				<configuration>
					<archive>
						<manifest>
							<mainClass>org.sidif.wiki.rest.WikiTaskServer</mainClass>
						</manifest>
					</archive>
					<descriptorRefs>
						<descriptorRef>jar-with-dependencies</descriptorRef>
					</descriptorRefs>
				</configuration>
				<executions>
					<execution>
						<id>make-assembly</id> <!-- this is used for inheritance merges -->
						<phase>package</phase> <!-- bind to the packaging phase -->
						<goals>
							<goal>single</goal>
						</goals>
					</execution>
				</executions>
			</plugin>
			<!-- Launch4 J plugin to create cross plattform java app -->
			<plugin>
				<groupId>com.akathist.maven.plugins.launch4j</groupId>
				<artifactId>launch4j-maven-plugin</artifactId>
				<version>${launch4j-maven-plugin.version}</version>
				<executions>
					<execution>
						<id>l4j-gui</id>
						<phase>package</phase>
						<goals>
							<goal>launch4j</goal>
						</goals>
						<configuration>
							<dontWrapJar>false</dontWrapJar>
							<headerType>console</headerType>
							<jar>target/com.bitplan.wikitask-${project.version}-jar-with-dependencies.jar</jar>
							<outfile>${project.build.directory}/wikitask.exe</outfile>
							<errTitle />
							<cmdLine />
							<chdir />
							<priority>normal</priority>
							<downloadUrl>http://java.com/download</downloadUrl>
							<supportUrl>http://wiki.bitplan.com/index.php/wikitask-java-api</supportUrl>
							<customProcName>false</customProcName>
							<stayAlive>false</stayAlive>
							<manifest />
							<icon />
							<jre>
								<path />
								<minVersion>1.8.0</minVersion>
								<maxVersion />
								<jdkPreference>preferJre</jdkPreference>
								<initialHeapSize>256</initialHeapSize>
								<maxHeapSize>3000</maxHeapSize>
							</jre>
							<!-- <splash> <file>${project.basedir}/src/main/build/Sunflower.bmp</file> 
								<waitForWindow>true</waitForWindow> <timeout>60</timeout> <timeoutErr>true</timeoutErr> 
								</splash> -->
							<versionInfo>
								<fileVersion>0.${project.version}</fileVersion>
								<txtFileVersion>${project.version}</txtFileVersion>
								<fileDescription>wikitask Java Api</fileDescription>
								<copyright>BITPlan GmbH</copyright>
								<productVersion>0.0.1.0</productVersion>
								<txtProductVersion>${project.version}</txtProductVersion>
								<productName>wikitask Java API</productName>
								<companyName>BITPlan GmbH</companyName>
								<internalName>wikitask</internalName>
								<originalFilename>wikitask.exe</originalFilename>
							</versionInfo>
						</configuration>
					</execution>
				</executions>
			</plugin>
			<!-- http://kosalads.blogspot.de/2013/04/maven-copy-artifact-in-to-separate.html 
				https://stackoverflow.com/a/16862404/1497139 -->
			<plugin>
				<artifactId>maven-antrun-plugin</artifactId>
				<version>${maven-antrun-plugin.version}</version>
				<configuration>
					<tasks>
						<copy
							file="target/com.bitplan.wikitask-${project.version}-jar-with-dependencies.jar"
							tofile="release/wikitask.jar" />
						<copy file="target/wikitask.exe"
							tofile="release/wikitask.exe" />
					</tasks>
				</configuration>
				<executions>
					<execution>
						<phase>install</phase>
						<goals>
							<goal>run</goal>
						</goals>
					</execution>
				</executions>
			</plugin>
		</plugins>
	</build>
</project>
