<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>

    <groupId>de.hdm_stuttgart.mi.sd1</groupId>
    <artifactId>sd1_2018summer_solve</artifactId>
    <version>0.9</version>
    <packaging>jar</packaging>

    <name>sd1_2018summer_solve</name>

    <url>https://freedocs.mi.hdm-stuttgart.de/sd1_sect_mavenCli.html</url>

    <properties>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>

    	<maven.compiler.target>17</maven.compiler.target>
        <maven.compiler.source>17</maven.compiler.source>

        <freedocs.url>https://freedocs.mi.hdm-stuttgart.de</freedocs.url>
        <mathjax.url>${freedocs.url}/lib/MathJax/es5/tex-chtml.js</mathjax.url>
        <libhighlight.url>${freedocs.url}/lib/highlight.js</libhighlight.url>
    </properties>

    <repositories>
        <repository>
            <id>hdm-mi-internal-maven-repo</id>
            <url>https://maven.mi.hdm-stuttgart.de/nexus/repository/mi-maven</url>
        </repository>
    </repositories>

    <dependencies>
        <dependency>
            <groupId>org.apache.logging.log4j</groupId>
            <artifactId>log4j-api</artifactId>
            <version>2.20.0</version>
        </dependency>

        <dependency>
            <groupId>org.apache.logging.log4j</groupId>
            <artifactId>log4j-core</artifactId>
            <version>2.20.0</version>
        </dependency>

        <dependency>
         <groupId>junit</groupId>
         <artifactId>junit</artifactId>
         <version>4.13.2</version>
         <scope>test</scope>
       </dependency>

        <dependency>
            <groupId>org.hamcrest</groupId>
            <artifactId>hamcrest-core</artifactId>
            <version>1.3</version>
            <scope>test</scope>
        </dependency>

        <dependency>
            <groupId>de.hdm_stuttgart.mi.exam</groupId>
            <artifactId>unitmarking</artifactId>
            <version>1.3</version>
        </dependency>
    </dependencies>

    <build>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>3.11.0</version>
            </plugin>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-antrun-plugin</artifactId>
                <version>3.1.0</version>
                <executions>
                    <execution>
                        <phase>generate-sources</phase>
                        <goals>
                            <goal>run</goal>
                        </goals>
                        <configuration>
                            <target>
                                <echo>Javadoc root at file://${project.basedir}/target/site/apidocs/index.html</echo>
                            </target>
                        </configuration>
                    </execution>
                </executions>
            </plugin>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
		        <artifactId>maven-javadoc-plugin</artifactId>
		        <version>3.5.0</version>
                <configuration>
                    <release>17</release>
                    <doclint>all</doclint>
                    <show>public</show>
                    <docfilessubdirs>true</docfilessubdirs>
                    <addStylesheets>
                        <stylesheet>resources/jdocSupplement.css</stylesheet>
                    </addStylesheets>

                    <windowtitle>Exam documentation</windowtitle>

                    <links>
                        <link>${freedocs.url}/doc/openjdk-21-doc/api/</link>
                    </links>

                    <additionalOptions>
                        <additionalOption>-html5 --allow-script-in-comments</additionalOption>
                    </additionalOptions>
                    <nohelp>true</nohelp>

                    <header><![CDATA[
            <script>
             MathJax = {
                chtml: { displayAlign: 'left',
                         displayIndent: '5ex'}
             };
            </script>
            <script type="text/javascript" src="${mathjax.url}"></script>
            <script type="text/javascript" src="{@docRoot}/resources/jdocSupplement.js"></script>
	    
            <link rel="stylesheet" href="${libhighlight.url}/styles/idea.min.css">
            <script src="${libhighlight.url}/highlight.min.js"></script>
            <script type="text/javascript">hljs.highlightAll();</script>]]>
                    </header>
                    <bottom><![CDATA[Copyright © 2023 Stuttgart Media University / MI. Licensed under
        <a style="font-weight:bold;" href="https://creativecommons.org/licenses/by/4.0/legalcode" target="_blank"
          >Creative Commons Attribution 4.0 International Public License</a>.]]></bottom>
                </configuration>
            </plugin>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-assembly-plugin</artifactId>
                <version>3.6.0</version>
                <configuration>
                    <descriptors>
                        <descriptor>src/main/assembly/assembly.xml</descriptor>
                    </descriptors>
                </configuration>
                <executions>
                    <execution>
                        <id>make-assembly</id>
                        <phase>package</phase>
                        <goals>
                            <goal>single</goal>
                        </goals>
                        <configuration>
                            <archive>
                                <manifest>
                                    <mainClass>de.hdm_stuttgart.mi.sd1.ShowReachedPoints</mainClass>
                                </manifest>
                            </archive>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>
</project>