<?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/xsd/maven-4.0.0.xsd">
	<modelVersion>4.0.0</modelVersion>

	<groupId>cat.inspiracio</groupId>
	<artifactId>html-parser</artifactId>
	<packaging>jar</packaging>
	<version>0.0.6</version>

	<name>cat.inspiracio:html-parser</name>
	<url>http://www.inspiracio.cat</url>

	<description>
HTML-parser provides a parser for HTML 5 that produces
HTML 5 document object model.

It aims to be a Java-implementation of 
http://www.w3.org/TR/html5/.

It is for use in the server. It does not implement features 
that are relevant in the client, like event handling.

It is for use from javascript, via Java's scripting library.
	</description> 

    <licenses>
        <license>
            <name>The Apache Software License, Version 2.0</name>
            <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
        </license>
    </licenses>

	<developers>
		<developer>
			<name>Alexander Bunkenburg</name>
			<email>alex@inspiracio.cat</email>
			<organization>inspiració.cat</organization>
			<organizationUrl>https://www.inspiracio.cat</organizationUrl>
		</developer>
	</developers>

	<!-- bitbucket -->
	<scm>
		<!-- read-only connection -->
		<connection>scm:git:git@bitbucket.org:bunkenburg/html-parser.git</connection>
		<!-- read and write access connection -->
		<developerConnection>scm:git:git@bitbucket.org:bunkenburg/html-parser.git</developerConnection>
		<!-- web front end -->
		<url>https://bitbucket.org/bunkenburg/html-parser</url>
	</scm>

	<properties>
		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
	</properties>
  
	<!-- http://central.sonatype.org/pages/apache-maven.html
		Release of a new version:
		mvn clean deploy
	-->  
	<distributionManagement>
		<snapshotRepository>
			<id>ossrh</id>
			<url>https://oss.sonatype.org/content/repositories/snapshots</url>
		</snapshotRepository>
	</distributionManagement>

	<build>
		<plugins>

			<!-- clean -->
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-clean-plugin</artifactId>
				<version>3.3.2</version>
			</plugin>

			<!-- versions -->
			<plugin>
				<groupId>org.codehaus.mojo</groupId>
				<artifactId>versions-maven-plugin</artifactId>
				<version>2.16.2</version>
				<executions>
					<execution>
						<phase>validate</phase>
						<goals>
							<goal>display-dependency-updates</goal>
							<goal>display-plugin-updates</goal>
						</goals>
					</execution>
				</executions>
			</plugin>

			<!-- enforces java version and maven version -->
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-enforcer-plugin</artifactId>
				<version>3.4.1</version>
				<executions>
					<execution>
						<id>enforce-versions</id>
						<phase>validate</phase>
						<goals><goal>enforce</goal></goals>
						<configuration>
							<rules>
								<!-- min maven version -->
								<requireMavenVersion><version>3.6.3</version></requireMavenVersion>
								<!-- exactly java 1.8 -->
								<requireJavaVersion><version>1.8</version></requireJavaVersion>
							</rules>
						</configuration>
					</execution>
				</executions>
			</plugin>

			<!-- compile -->
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-compiler-plugin</artifactId>
				<version>3.13.0</version>
				<configuration>
					<source>1.8</source>
					<target>1.8</target>
					<debug>true</debug>
					<debuglevel>lines,vars,source</debuglevel>
				</configuration>
			</plugin>

       		<!-- nexus -->
			<plugin>
				<groupId>org.sonatype.plugins</groupId>
				<artifactId>nexus-staging-maven-plugin</artifactId>
				<version>1.6.13</version>
				<extensions>true</extensions>
				<configuration>
					<serverId>ossrh</serverId>
					<nexusUrl>https://oss.sonatype.org/</nexusUrl>
					<autoReleaseAfterClose>true</autoReleaseAfterClose>
				</configuration>
			</plugin>

			<!-- source.jar -->
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-source-plugin</artifactId>
				<version>3.3.1</version>
				<executions>
					<execution>
						<id>attach-sources</id>
						<goals><goal>jar</goal></goals>
					</execution>
				</executions>
			</plugin>
    
			<!-- javadoc.jar -->
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-javadoc-plugin</artifactId>
				<version>3.6.3</version>
				<executions>
					<execution>
						<id>attach-javadocs</id>
						<goals><goal>jar</goal></goals>
						<configuration>
							<source>8</source>
							<!--failOnError>false</failOnError-->
						</configuration>
					</execution>
				</executions>
			</plugin>

			<!-- gpg signing -->
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-gpg-plugin</artifactId>
				<version>3.2.4</version>
				<executions>
					<execution>
						<id>sign-artifacts</id>
						<phase>verify</phase>
						<goals><goal>sign</goal></goals>
					</execution>
				</executions>
			</plugin>

			<!-- deploy -->
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-deploy-plugin</artifactId>
				<version>3.1.2</version>
			</plugin>

			<!-- install -->
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-install-plugin</artifactId>
				<version>3.1.2</version>
			</plugin>

			<!-- jar -->
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-jar-plugin</artifactId>
				<version>3.4.1</version>
			</plugin>

			<!-- resources -->
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-resources-plugin</artifactId>
				<version>3.3.1</version>
			</plugin>

			<!-- site -->
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-site-plugin</artifactId>
				<version>4.0.0-M13</version>
			</plugin>

			<!-- surefire -->
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-surefire-plugin</artifactId>
				<version>3.2.5</version>
			</plugin>

		</plugins>
	</build>

	<dependencies>

		<!-- normal ============================================================ -->

		<!-- nu.validator.htmlparser -->
		<!-- I have a hack in HTMLDocumentImp.createElement that makes upgrading this a bit more work.-->
		<dependency>
			<groupId>nu.validator.htmlparser</groupId>
			<artifactId>htmlparser</artifactId>
			<version>1.4</version>
		</dependency>
		<!-- https://mvnrepository.com/artifact/nu.validator/htmlparser -->
		<!--dependency>
			<groupId>nu.validator</groupId>
			<artifactId>htmlparser</artifactId>
			<version>1.4.16</version>
		</dependency-->

		<!-- url-parser -->
		<dependency>
			<groupId>cat.inspiracio</groupId>
			<artifactId>url-parser</artifactId>
			<version>0.0.1</version>
		</dependency>

		<!-- I need xerces because HTMLDocumentImp extends org.apache.xerces.dom.DocumentImpl -->
		<dependency>
			<groupId>xerces</groupId>
			<artifactId>xercesImpl</artifactId>
			<version>2.12.2</version>
		</dependency>

		<!-- test   ============================================================ -->

		<!-- junit -->
		<dependency>
			<groupId>junit</groupId>
			<artifactId>junit</artifactId>
			<version>4.13.2</version>
			<scope>test</scope>
		</dependency>
		
	</dependencies>
</project>
