forked from asciidoctor/asciidoctor-maven-plugin
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
closes asciidoctor#188: sets html5 as default backend
- Loading branch information
1 parent
afdfc3c
commit 6bf7890
Showing
5 changed files
with
68 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
invoker.goals=clean asciidoctor:process-asciidoc |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
<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"> | ||
<modelVersion>4.0.0</modelVersion> | ||
|
||
<groupId>org.asciidoctor</groupId> | ||
<artifactId>test</artifactId> | ||
<version>1.0-SNAPSHOT</version> | ||
|
||
<name>Converts Asciidoctor Article to Html</name> | ||
<description>Runs asciidoctor-maven-plugin:process-asciidoc</description> | ||
|
||
<properties> | ||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> | ||
</properties> | ||
|
||
<build> | ||
<plugins> | ||
<plugin> | ||
<groupId>org.asciidoctor</groupId> | ||
<artifactId>asciidoctor-maven-plugin</artifactId> | ||
<version>@project.version@</version> | ||
</plugin> | ||
</plugins> | ||
</build> | ||
</project> |
25 changes: 25 additions & 0 deletions
25
src/it/uses-html5-as-default-backend/src/main/asciidoc/sample.asciidoc
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
Document Title | ||
============== | ||
Doc Writer <thedoc@asciidoctor.org> | ||
:idprefix: id_ | ||
|
||
Preamble paragraph. | ||
|
||
NOTE: This is test, only a test. | ||
|
||
== Section A | ||
|
||
*Section A* paragraph. | ||
|
||
=== Section A Subsection | ||
|
||
*Section A* 'subsection' paragraph. | ||
|
||
== Section B | ||
|
||
*Section B* paragraph. | ||
|
||
.Section B list | ||
* Item 1 | ||
* Item 2 | ||
* Item 3 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
final File outputDir = new File(basedir, "target/generated-docs"); | ||
|
||
final def expectedFiles = ["sample.html"] | ||
|
||
expectedFiles.each { it -> | ||
File file = new File(outputDir, it); | ||
System.out.println("Checking for existence of " + file) | ||
if (!file.exists() || !file.isFile()) { | ||
throw new Exception("Missing file " + file) | ||
} | ||
if (!file.text.startsWith("<!DOCTYPE html>")) { | ||
throw new Exception("Expected file does not contain HTML: " + file) | ||
} | ||
} | ||
|
||
return true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters