Skip to content

Latest commit

 

History

History
68 lines (52 loc) · 2.71 KB

README.md

File metadata and controls

68 lines (52 loc) · 2.71 KB

License Build status Maven Central Version

html-maven-plugin

This maven plugin adds a build lifecycle to build and deploy html sites from asciidoc and markdown files. It deploys the generated html either as a directory - on file after another - or as zip file.

usage

To add this plugin to your build add the following to your pom:

...
<build>
    <plugins>
        <plugin>
            <groupId>de.eitco.cicd.html</groupId>
            <artifactId>html-maven-plugin</artifactId>
            <version>4.0.1</version>
            <extensions>true</extensions>
        </plugin>
    </plugins>
</build>

Now you can activate one of the lifecycles this plugin provides. To generate a directory containing your generated html files and resources use the html lifecycle:

<?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>your.group.id</groupId>
    <artifactId>your-artifact-id</artifactId>
    <version>0.0.1-SNAPSHOT</version>
    <packaging>html</packaging>
...
</project>

To generate a zip containing your generated html files and resources us the html-zip lifecycle

<?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>your.group.id</groupId>
    <artifactId>your-artifact-id</artifactId>
    <version>0.0.1-SNAPSHOT</version>
    <packaging>html-zip</packaging>
...
</project>

Add your asciidoc file to src/main/asciidoc, your images and plain html files to src/main/web-resources and/or your markdown files to src/main/markdown.

  • A complete reference about the goals and parameters of this plugin can be found here.
  • The integration tests provide some examples about how to use this plugin