From 4bcf33ab156d78a8547f7677e33641ce5e526aaf Mon Sep 17 00:00:00 2001 From: Abel Salgado Romero Date: Wed, 9 Oct 2024 23:56:50 +0200 Subject: [PATCH 01/12] Add compatibility with latest maven-site-plugin v3.20.0 * Bump Doxia to same versions as maven-site-plugin * Apply required code changes --- asciidoctor-converter-doxia-module/pom.xml | 2 +- .../src/it/maven-site-plugin/pom.xml | 3 +-- .../site/AsciidoctorConverterDoxiaParser.java | 16 ++++++++++------ asciidoctor-parser-doxia-module/pom.xml | 2 +- .../src/it/maven-site-plugin/pom.xml | 2 +- .../site/parser/AsciidoctorAstDoxiaParser.java | 15 +++++++++------ .../test/TestNodeProcessorFactory.java | 4 ++-- .../pages/compatibility-matrix.adoc | 8 ++++++-- pom.xml | 3 ++- 9 files changed, 33 insertions(+), 22 deletions(-) diff --git a/asciidoctor-converter-doxia-module/pom.xml b/asciidoctor-converter-doxia-module/pom.xml index cdfc6ebe..d2cca455 100644 --- a/asciidoctor-converter-doxia-module/pom.xml +++ b/asciidoctor-converter-doxia-module/pom.xml @@ -46,7 +46,7 @@ org.apache.maven.doxia doxia-site-renderer - 1.11.1 + ${doxia.sitetools.version} test diff --git a/asciidoctor-converter-doxia-module/src/it/maven-site-plugin/pom.xml b/asciidoctor-converter-doxia-module/src/it/maven-site-plugin/pom.xml index 1ce5cb7a..139ab88b 100644 --- a/asciidoctor-converter-doxia-module/src/it/maven-site-plugin/pom.xml +++ b/asciidoctor-converter-doxia-module/src/it/maven-site-plugin/pom.xml @@ -28,8 +28,7 @@ org.apache.maven.plugins maven-site-plugin - - 3.12.1 + 3.20.0 ${project.basedir}/src/site/asciidoc diff --git a/asciidoctor-converter-doxia-module/src/main/java/org/asciidoctor/maven/site/AsciidoctorConverterDoxiaParser.java b/asciidoctor-converter-doxia-module/src/main/java/org/asciidoctor/maven/site/AsciidoctorConverterDoxiaParser.java index 2f4740a2..835a6118 100644 --- a/asciidoctor-converter-doxia-module/src/main/java/org/asciidoctor/maven/site/AsciidoctorConverterDoxiaParser.java +++ b/asciidoctor-converter-doxia-module/src/main/java/org/asciidoctor/maven/site/AsciidoctorConverterDoxiaParser.java @@ -5,7 +5,6 @@ import java.io.File; import java.io.IOException; import java.io.Reader; -import java.util.logging.Logger; import org.apache.maven.doxia.parser.AbstractTextParser; import org.apache.maven.doxia.parser.ParseException; @@ -26,6 +25,8 @@ import org.codehaus.plexus.component.annotations.Component; import org.codehaus.plexus.util.IOUtil; import org.codehaus.plexus.util.xml.Xpp3Dom; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; /** * This class is used by the Doxia framework @@ -39,6 +40,8 @@ @Component(role = Parser.class, hint = AsciidoctorConverterDoxiaParser.ROLE_HINT) public class AsciidoctorConverterDoxiaParser extends AbstractTextParser { + private final Logger logger = LoggerFactory.getLogger(AsciidoctorConverterDoxiaParser.class); + @Inject protected Provider mavenProjectProvider; @@ -58,7 +61,7 @@ public void parse(Reader reader, Sink sink, String reference) throws ParseExcept source = ""; } } catch (IOException ex) { - getLog().error("Could not read AsciiDoc source: " + ex.getLocalizedMessage()); + logger.error("Could not read AsciiDoc source: {}", ex.getLocalizedMessage()); return; } @@ -86,7 +89,7 @@ public void parse(Reader reader, Sink sink, String reference) throws ParseExcept try { // process log messages according to mojo configuration - new LogRecordsProcessors(logHandler, siteDirectory, errorMessage -> getLog().error(errorMessage)) + new LogRecordsProcessors(logHandler, siteDirectory, errorMessage -> logger.error(errorMessage)) .processLogRecords(memoryLogHandler); } catch (Exception exception) { throw new ParseException(exception.getMessage(), exception); @@ -102,10 +105,11 @@ public void parse(Reader reader, Sink sink, String reference) throws ParseExcept private MemoryLogHandler asciidoctorLoggingSetup(Asciidoctor asciidoctor, LogHandler logHandler, File siteDirectory) { final MemoryLogHandler memoryLogHandler = new MemoryLogHandler(logHandler.getOutputToConsole(), - logRecord -> getLog().info(LogRecordFormatter.format(logRecord, siteDirectory))); + logRecord -> logger.info(LogRecordFormatter.format(logRecord, siteDirectory))); asciidoctor.registerLogHandler(memoryLogHandler); // disable default console output of AsciidoctorJ - Logger.getLogger("asciidoctor").setUseParentHandlers(false); + // TODO validate if still needed + java.util.logging.Logger.getLogger("asciidoctor").setUseParentHandlers(false); return memoryLogHandler; } @@ -147,7 +151,7 @@ private void requireLibrary(Asciidoctor asciidoctor, String require) { try { asciidoctor.requireLibrary(require); } catch (Exception ex) { - getLog().error(ex.getLocalizedMessage()); + logger.error(ex.getLocalizedMessage()); } } } diff --git a/asciidoctor-parser-doxia-module/pom.xml b/asciidoctor-parser-doxia-module/pom.xml index 9f753b71..f2a6a558 100644 --- a/asciidoctor-parser-doxia-module/pom.xml +++ b/asciidoctor-parser-doxia-module/pom.xml @@ -46,7 +46,7 @@ org.apache.maven.doxia doxia-site-renderer - 1.11.1 + ${doxia.sitetools.version} test diff --git a/asciidoctor-parser-doxia-module/src/it/maven-site-plugin/pom.xml b/asciidoctor-parser-doxia-module/src/it/maven-site-plugin/pom.xml index 393d8c4d..d78941ac 100644 --- a/asciidoctor-parser-doxia-module/src/it/maven-site-plugin/pom.xml +++ b/asciidoctor-parser-doxia-module/src/it/maven-site-plugin/pom.xml @@ -23,7 +23,7 @@ org.apache.maven.plugins maven-site-plugin - 3.12.1 + 3.20.0 ${project.basedir}/src/site/asciidoc diff --git a/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/AsciidoctorAstDoxiaParser.java b/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/AsciidoctorAstDoxiaParser.java index ebe72db0..23d077f4 100644 --- a/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/AsciidoctorAstDoxiaParser.java +++ b/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/AsciidoctorAstDoxiaParser.java @@ -23,14 +23,15 @@ import org.asciidoctor.maven.log.LogRecordFormatter; import org.asciidoctor.maven.log.LogRecordsProcessors; import org.asciidoctor.maven.log.MemoryLogHandler; -import org.asciidoctor.maven.site.HeaderMetadata; import org.asciidoctor.maven.site.HeadParser; +import org.asciidoctor.maven.site.HeaderMetadata; import org.asciidoctor.maven.site.SiteConversionConfiguration; import org.asciidoctor.maven.site.SiteConversionConfigurationParser; import org.asciidoctor.maven.site.SiteLogHandlerDeserializer; import org.codehaus.plexus.component.annotations.Component; import org.codehaus.plexus.util.IOUtil; import org.codehaus.plexus.util.xml.Xpp3Dom; +import org.slf4j.LoggerFactory; import static org.asciidoctor.maven.commons.StringUtils.isNotBlank; @@ -45,6 +46,8 @@ @Component(role = Parser.class, hint = AsciidoctorAstDoxiaParser.ROLE_HINT) public class AsciidoctorAstDoxiaParser extends AbstractTextParser { + private final org.slf4j.Logger logger = LoggerFactory.getLogger(AsciidoctorAstDoxiaParser.class); + @Inject protected Provider mavenProjectProvider; @@ -64,7 +67,7 @@ public void parse(Reader reader, Sink sink, String reference) throws ParseExcept source = ""; } } catch (IOException ex) { - getLog().error("Could not read AsciiDoc source: " + ex.getLocalizedMessage()); + logger.error("Could not read AsciiDoc source: {}", ex.getLocalizedMessage()); return; } @@ -88,13 +91,13 @@ public void parse(Reader reader, Sink sink, String reference) throws ParseExcept final MemoryLogHandler memoryLogHandler = asciidoctorLoggingSetup(asciidoctor, logHandler, siteDirectory); if (isNotBlank(reference)) - getLog().debug("Document loaded: " + reference); + logger.debug("Document loaded: {}", reference); Document document = asciidoctor.load(source, conversionConfig.getOptions()); try { // process log messages according to mojo configuration - new LogRecordsProcessors(logHandler, siteDirectory, errorMessage -> getLog().error(errorMessage)) + new LogRecordsProcessors(logHandler, siteDirectory, errorMessage -> logger.error(errorMessage)) .processLogRecords(memoryLogHandler); } catch (Exception exception) { @@ -116,7 +119,7 @@ public void parse(Reader reader, Sink sink, String reference) throws ParseExcept private MemoryLogHandler asciidoctorLoggingSetup(Asciidoctor asciidoctor, LogHandler logHandler, File siteDirectory) { final MemoryLogHandler memoryLogHandler = new MemoryLogHandler(logHandler.getOutputToConsole(), - logRecord -> getLog().info(LogRecordFormatter.format(logRecord, siteDirectory))); + logRecord -> logger.info(LogRecordFormatter.format(logRecord, siteDirectory))); asciidoctor.registerLogHandler(memoryLogHandler); // disable default console output of AsciidoctorJ Logger.getLogger("asciidoctor").setUseParentHandlers(false); @@ -161,7 +164,7 @@ private void requireLibrary(Asciidoctor asciidoctor, String require) { try { asciidoctor.requireLibrary(require); } catch (Exception ex) { - getLog().error(ex.getLocalizedMessage()); + logger.error(ex.getLocalizedMessage()); } } } diff --git a/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/processors/test/TestNodeProcessorFactory.java b/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/processors/test/TestNodeProcessorFactory.java index 875e5404..d96e4445 100644 --- a/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/processors/test/TestNodeProcessorFactory.java +++ b/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/processors/test/TestNodeProcessorFactory.java @@ -5,7 +5,7 @@ import lombok.SneakyThrows; import org.apache.commons.lang3.tuple.Pair; import org.apache.maven.doxia.sink.Sink; -import org.apache.maven.doxia.siterenderer.RenderingContext; +import org.apache.maven.doxia.siterenderer.DocumentRenderingContext; import org.apache.maven.doxia.siterenderer.sink.SiteRendererSink; import org.asciidoctor.maven.site.parser.NodeProcessor; import org.mockito.Mockito; @@ -20,6 +20,6 @@ public static Pair create(Class clazz) { } public static Sink createSink() { - return new SiteRendererSink(Mockito.mock(RenderingContext.class)); + return new SiteRendererSink(Mockito.mock(DocumentRenderingContext.class)); } } diff --git a/docs/modules/site-integration/pages/compatibility-matrix.adoc b/docs/modules/site-integration/pages/compatibility-matrix.adoc index 68f293e9..89fbeaa5 100644 --- a/docs/modules/site-integration/pages/compatibility-matrix.adoc +++ b/docs/modules/site-integration/pages/compatibility-matrix.adoc @@ -10,8 +10,12 @@ Versions not listed below are not supported, please consider upgrading. |=== |Asciidoctor Doxia Module | Maven Site Plugin | Supported -|v3.x.x -|v3.1x.x +|v3.0.x +|v3.12.x +|Yes + +|v3.1.x +|v3.20.x |Yes |=== diff --git a/pom.xml b/pom.xml index d959e0aa..2eaa1301 100644 --- a/pom.xml +++ b/pom.xml @@ -71,7 +71,8 @@ UTF-8 11 3.9.9 - 1.12.0 + 2.0.0-M12 + 2.0.0-M19 2.2.0 3.0.0 9.4.6.0 From 2ca02920f836d87df7d4020a13d9e0bb09a47cc5 Mon Sep 17 00:00:00 2001 From: Abel Salgado Romero Date: Thu, 10 Oct 2024 00:02:42 +0200 Subject: [PATCH 02/12] Update changelog --- CHANGELOG.adoc | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.adoc b/CHANGELOG.adoc index c4fe4bca..fd9c59ef 100644 --- a/CHANGELOG.adoc +++ b/CHANGELOG.adoc @@ -20,6 +20,7 @@ Bug Fixes:: Improvements:: * Added support for AsciidoctorJ v3.0.0 (#651) + * Add compatibility with maven-site-plugin v3.20.0 (#934) Build / Infrastructure:: From 266ae3c4d86b1a5c6c0d8a74e8e49e9e991e114b Mon Sep 17 00:00:00 2001 From: Abel Salgado Romero Date: Thu, 10 Oct 2024 17:54:30 +0200 Subject: [PATCH 03/12] Fix SectionNodeProcessor and Test, OrderedListNodeProcessorTest --- .../processors/SectionNodeProcessor.java | 63 ++++++++----------- .../OrderedListNodeProcessorTest.java | 10 +-- .../processors/SectionNodeProcessorTest.java | 30 ++++----- 3 files changed, 47 insertions(+), 56 deletions(-) diff --git a/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/processors/SectionNodeProcessor.java b/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/processors/SectionNodeProcessor.java index c637fbb1..e75d665d 100644 --- a/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/processors/SectionNodeProcessor.java +++ b/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/processors/SectionNodeProcessor.java @@ -5,6 +5,8 @@ import org.asciidoctor.ast.StructuralNode; import org.asciidoctor.jruby.ast.impl.SectionImpl; import org.asciidoctor.maven.site.parser.NodeProcessor; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; /** * Section title processor. @@ -15,6 +17,8 @@ */ public class SectionNodeProcessor extends AbstractSinkNodeProcessor implements NodeProcessor { + private final Logger logger = LoggerFactory.getLogger(SectionNodeProcessor.class); + /** * Constructor. * @@ -36,45 +40,32 @@ public void process(StructuralNode node) { private void sectionTitle(Sink sink, int level, String title, Section node) { final String formattedTitle = formatTitle(title, node); - switch (level) { - case 0: - // Kept for completeness, real document title is treated in - // DocumentNodeProcessor - sink.rawText("

" + formattedTitle + "

"); - break; - case 1: - sink.sectionTitle1(); - sink.text(formattedTitle); - sink.sectionTitle1_(); - break; - case 2: - sink.sectionTitle2(); - sink.text(formattedTitle); - sink.sectionTitle2_(); - break; - case 3: - sink.sectionTitle3(); - sink.text(formattedTitle); - sink.sectionTitle3_(); - break; - case 4: - sink.sectionTitle4(); - sink.text(formattedTitle); - sink.sectionTitle4_(); - break; - case 5: - sink.sectionTitle5(); - sink.text(formattedTitle); - sink.sectionTitle5_(); - break; - case 6: - sink.sectionTitle6(); - sink.text(formattedTitle); - sink.sectionTitle6_(); - break; + if (level == 0) { + // Kept for completeness, real document title is treated in + // DocumentNodeProcessor + sink.sectionTitle1(); + sink.text(formattedTitle); + sink.sectionTitle1_(); + } else { + // Asciidoctor supports up o 6 levels, but Xhtml5BaseSink only up to 5 + int siteLevel = level + 1; + if (level >= 5) { + // TODO generate code manually or request change + logger.warn("Site module does not support level 6 sections. Re-writing as 5"); + siteLevel = 5; + } + sink.sectionTitle(siteLevel, null); + anchor(sink, node); + sink.text(formattedTitle); + sink.sectionTitle_(siteLevel); } } + private void anchor(Sink sink, Section node) { + sink.anchor(node.getId()); + sink.anchor_(); + } + private String formatTitle(String title, Section node) { final Boolean numbered = node.isNumbered(); final Long sectnumlevels = getSectnumlevels(node); diff --git a/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/processors/OrderedListNodeProcessorTest.java b/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/processors/OrderedListNodeProcessorTest.java index e29d9d2a..c47f64ae 100644 --- a/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/processors/OrderedListNodeProcessorTest.java +++ b/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/processors/OrderedListNodeProcessorTest.java @@ -39,7 +39,7 @@ void should_convert_simple_list() { String html = process(content); assertThat(html) - .isEqualTo("
    " + + .isEqualTo("
      " + "
    1. ordered item 1
    2. " + "
    3. ordered item 2
    "); } @@ -51,15 +51,15 @@ void should_convert_nested_list() { String html = process(content); assertThat(html) - .isEqualTo("
      " + + .isEqualTo("
        " + "
      1. ordered item 1" + - "
          " + + "
            " + "
          1. ordered item 1 1
          " + "
        1. ordered item 1 2
        2. " + "
        3. ordered item 2" + - "
            " + + "
              " + "
            1. ordered item 2 1" + - "
                " + + "
                  " + "
                1. ordered item 2 1 1
            "); } diff --git a/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/processors/SectionNodeProcessorTest.java b/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/processors/SectionNodeProcessorTest.java index 69fb9672..cb3cc0f3 100644 --- a/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/processors/SectionNodeProcessorTest.java +++ b/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/processors/SectionNodeProcessorTest.java @@ -38,7 +38,7 @@ void should_convert_section_level_2() { String html = process(content, 1); assertThat(html) - .isEqualTo("

            First section title

            "); + .isEqualTo("

            First section title

            "); } @Test @@ -48,7 +48,7 @@ void should_convert_section_level_3() { String html = process(content, 2); assertThat(html) - .isEqualTo("

            Second section title

            "); + .isEqualTo("

            Second section title

            "); } @Test @@ -58,7 +58,7 @@ void should_convert_section_level_4() { String html = process(content, 3); assertThat(html) - .isEqualTo("

            Third section title

            "); + .isEqualTo("

            Third section title

            "); } @Test @@ -68,7 +68,7 @@ void should_convert_section_level_5() { String html = process(content, 4); assertThat(html) - .isEqualTo("
            Fourth section title
            "); + .isEqualTo("
            Fourth section title
            "); } @Test @@ -78,7 +78,7 @@ void should_convert_section_level_6() { String html = process(content, 5); assertThat(html) - .isEqualTo("
            Fifth section title
            "); + .isEqualTo("
            Fifth section title
            "); } @Test @@ -90,17 +90,17 @@ void should_convert_section_with_sectionNumbers() { // With numbering assertThat(process(content, 1, attributes)) - .isEqualTo("

            1. First section title

            "); + .isEqualTo("

            1. First section title

            "); assertThat(process(content, 2, attributes)) - .isEqualTo("

            1.1. Second section title

            "); + .isEqualTo("

            1.1. Second section title

            "); assertThat(process(content, 3, attributes)) - .isEqualTo("

            1.1.1. Third section title

            "); + .isEqualTo("

            1.1.1. Third section title

            "); // Without numbering by default assertThat(process(content, 4, attributes)) - .isEqualTo("
            Fourth section title
            "); + .isEqualTo("
            Fourth section title
            "); assertThat(process(content, 5, attributes)) - .isEqualTo("
            Fifth section title
            "); + .isEqualTo("
            Fifth section title
            "); } @Test @@ -113,15 +113,15 @@ void should_convert_section_with_sectionNumbers_and_sectNumLevels() { // With numbering assertThat(process(content, 1, attributes)) - .isEqualTo("

            1. First section title

            "); + .isEqualTo("

            1. First section title

            "); assertThat(process(content, 2, attributes)) - .isEqualTo("

            1.1. Second section title

            "); + .isEqualTo("

            1.1. Second section title

            "); assertThat(process(content, 3, attributes)) - .isEqualTo("

            1.1.1. Third section title

            "); + .isEqualTo("

            1.1.1. Third section title

            "); assertThat(process(content, 4, attributes)) - .isEqualTo("
            1.1.1.1. Fourth section title
            "); + .isEqualTo("
            1.1.1.1. Fourth section title
            "); assertThat(process(content, 5, attributes)) - .isEqualTo("
            1.1.1.1.1. Fifth section title
            "); + .isEqualTo("
            1.1.1.1.1. Fifth section title
            "); } private String documentWithSections() { From 24c8bdf49fc71590893e9495acf509df484a3873 Mon Sep 17 00:00:00 2001 From: Abel Salgado Romero Date: Thu, 10 Oct 2024 18:04:34 +0200 Subject: [PATCH 04/12] Fix TableNodeProcessorTest --- .../processors/TableNodeProcessorTest.java | 35 +++++++++---------- 1 file changed, 17 insertions(+), 18 deletions(-) diff --git a/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/processors/TableNodeProcessorTest.java b/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/processors/TableNodeProcessorTest.java index 2221a989..5bea20d9 100644 --- a/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/processors/TableNodeProcessorTest.java +++ b/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/processors/TableNodeProcessorTest.java @@ -45,15 +45,15 @@ void should_convert_table_with_header() { // Header for now is just first row with class=a assertThat(html) - .isEqualTo("" + + .isEqualTo("
            " + "" + "" + "" + "" + - "" + + "" + "" + "" + - "" + + "" + "
            NameLanguage
            JRubyJRubyJava
            RubiniusRubiniusRuby
            "); } @@ -64,12 +64,12 @@ void should_convert_table_without_header() { String html = process(content); assertThat(html) - .isEqualTo(clean("" + + .isEqualTo(clean("
            " + "" + - "" + + "" + "" + "" + - "" + + "" + "
            JRubyJRubyJava
            RubiniusRubiniusRuby
            ")); } @@ -90,13 +90,12 @@ void should_convert_table_with_label_and_title() { String html = process(content); assertThat(html) - .startsWith("") - .isEqualTo("
            Table 1. Table caption…​or title
            " + + .isEqualTo("
            Table 1. Table caption…​or title
            " + "" + - "" + + "" + "" + "" + - "" + + "" + "
            Table 1. Table caption…​or title
            JRubyJRubyJava
            RubiniusRubiniusRuby
            "); } @@ -123,29 +122,29 @@ void should_convert_table_with_labels_disabled_globally() { } private static String expectedNoLabelBeginning() { - return ""; + return "
            Table caption…​or title
            "; } private static String expectedTableWithoutLabel() { - return "
            Table caption…​or title
            " + + return "
            Table caption…​or title
            " + "" + - "" + + "" + "" + "" + - "" + + "" + "
            Table caption…​or title
            JRubyJRubyJava
            RubiniusRubiniusRuby
            "; } private static String expectedTableWithoutCaption() { - return "" + + return "
            " + "" + - "" + + "" + "" + "" + - "" + + "" + "" + "" + - "" + + "" + "
            JRubyJRubyJava
            RubiniusRubiniusRuby
            OpalOpalJavaScript
            "; } From 0d4ed8182fed40903cc5f463e731aad187e57d95 Mon Sep 17 00:00:00 2001 From: Abel Salgado Romero Date: Thu, 10 Oct 2024 18:08:47 +0200 Subject: [PATCH 05/12] Fix AsciidoctorAstDoxiaParserTest --- .../site/parser/AsciidoctorAstDoxiaParserTest.java | 12 ++++++------ .../maven/site/parser/processors/test/Html.java | 2 +- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/AsciidoctorAstDoxiaParserTest.java b/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/AsciidoctorAstDoxiaParserTest.java index 6b1ef90e..2a836449 100644 --- a/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/AsciidoctorAstDoxiaParserTest.java +++ b/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/AsciidoctorAstDoxiaParserTest.java @@ -44,18 +44,18 @@ void should_convert_html_without_any_configuration() throws FileNotFoundExceptio String result = parse(parser, srcAsciidoc); assertThat(result) - .isEqualTo("

            Document Title

            " + - "

            Preamble paragraph.

            " + - "

            Section A

            " + + .isEqualTo("

            Document Title

            Preamble paragraph.

            " + + "

            Section A

            " + "

            Section A paragraph.

            " + - "

            Section A Subsection

            " + + "

            Section A Subsection

            " + "

            Section A 'subsection' paragraph.

            " + - "

            Section B

            " + + "

            Section B

            " + "

            Section B paragraph.

            " + "
              " + "
            • Item 1
            • " + "
            • Item 2
            • " + - "
            • Item 3
            require 'asciidoctor'
            "); + "
          1. Item 3
          2. " + + "
            require 'asciidoctor'
            "); } @Test diff --git a/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/processors/test/Html.java b/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/processors/test/Html.java index 68d54f8f..43061dc5 100644 --- a/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/processors/test/Html.java +++ b/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/processors/test/Html.java @@ -2,7 +2,7 @@ public class Html { - public static final String LIST_STYLE_TYPE_DECIMAL = "list-style-type: decimal"; + public static final String LIST_STYLE_TYPE_DECIMAL = "list-style-type: decimal;"; public static String strong(String text) { return htmlElement("strong", text); From d75ecb191f39c20c0a314c1fd92e67b3a13da036 Mon Sep 17 00:00:00 2001 From: Abel Salgado Romero Date: Thu, 10 Oct 2024 18:10:59 +0200 Subject: [PATCH 06/12] Use javax.inject.Named instead of org.codehaus.plexus.component.annotations.Component --- .../maven/site/parser/AsciidoctorAstDoxiaParser.java | 5 ++--- .../maven/site/parser/AsciidoctorAstDoxiaParserModule.java | 6 +++--- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/AsciidoctorAstDoxiaParser.java b/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/AsciidoctorAstDoxiaParser.java index 23d077f4..06a0fffa 100644 --- a/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/AsciidoctorAstDoxiaParser.java +++ b/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/AsciidoctorAstDoxiaParser.java @@ -1,6 +1,7 @@ package org.asciidoctor.maven.site.parser; import javax.inject.Inject; +import javax.inject.Named; import javax.inject.Provider; import java.io.File; import java.io.IOException; @@ -9,7 +10,6 @@ import org.apache.maven.doxia.parser.AbstractTextParser; import org.apache.maven.doxia.parser.ParseException; -import org.apache.maven.doxia.parser.Parser; import org.apache.maven.doxia.sink.Sink; import org.apache.maven.project.MavenProject; import org.asciidoctor.Asciidoctor; @@ -28,7 +28,6 @@ import org.asciidoctor.maven.site.SiteConversionConfiguration; import org.asciidoctor.maven.site.SiteConversionConfigurationParser; import org.asciidoctor.maven.site.SiteLogHandlerDeserializer; -import org.codehaus.plexus.component.annotations.Component; import org.codehaus.plexus.util.IOUtil; import org.codehaus.plexus.util.xml.Xpp3Dom; import org.slf4j.LoggerFactory; @@ -43,7 +42,7 @@ * @author abelsromero * @since 3.0.0 */ -@Component(role = Parser.class, hint = AsciidoctorAstDoxiaParser.ROLE_HINT) +@Named(AsciidoctorAstDoxiaParser.ROLE_HINT) public class AsciidoctorAstDoxiaParser extends AbstractTextParser { private final org.slf4j.Logger logger = LoggerFactory.getLogger(AsciidoctorAstDoxiaParser.class); diff --git a/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/AsciidoctorAstDoxiaParserModule.java b/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/AsciidoctorAstDoxiaParserModule.java index 0ecd381d..1d1a7292 100644 --- a/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/AsciidoctorAstDoxiaParserModule.java +++ b/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/AsciidoctorAstDoxiaParserModule.java @@ -1,8 +1,8 @@ package org.asciidoctor.maven.site.parser; +import javax.inject.Named; + import org.apache.maven.doxia.parser.module.AbstractParserModule; -import org.apache.maven.doxia.parser.module.ParserModule; -import org.codehaus.plexus.component.annotations.Component; /** * This class is the entry point for integration with the Maven Site Plugin @@ -13,7 +13,7 @@ * @author abelsromero * @since 3.0.0 */ -@Component(role = ParserModule.class, hint = AsciidoctorAstDoxiaParser.ROLE_HINT) +@Named(AsciidoctorAstDoxiaParser.ROLE_HINT) public class AsciidoctorAstDoxiaParserModule extends AbstractParserModule { /** From 6ac0998b89e5ff212656d040e4987b7a874141dd Mon Sep 17 00:00:00 2001 From: Abel Salgado Romero Date: Thu, 10 Oct 2024 18:20:18 +0200 Subject: [PATCH 07/12] Fix NPE in ImageNodeProcessor --- .../maven/site/parser/processors/ImageNodeProcessor.java | 4 +++- .../org/asciidoctor/maven/site/parser/NodeSinkerTest.java | 7 ++++--- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/processors/ImageNodeProcessor.java b/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/processors/ImageNodeProcessor.java index 74c45286..6e372328 100644 --- a/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/processors/ImageNodeProcessor.java +++ b/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/processors/ImageNodeProcessor.java @@ -40,7 +40,9 @@ public void process(StructuralNode node) { final String imagesdir = (String) node.getAttribute("imagesdir"); String imagePath = isBlank(imagesdir) ? target : formatPath(imagesdir, target); final SinkEventAttributeSet attributes = new SinkEventAttributeSet(); - attributes.addAttribute(Attribute.ALT, alt); + if (!isBlank(alt)) + attributes.addAttribute(Attribute.ALT, alt); + getSink().figureGraphics(imagePath, attributes); } diff --git a/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/NodeSinkerTest.java b/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/NodeSinkerTest.java index 39756a46..ece9f114 100644 --- a/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/NodeSinkerTest.java +++ b/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/NodeSinkerTest.java @@ -1,5 +1,8 @@ package org.asciidoctor.maven.site.parser; +import java.io.StringWriter; +import java.util.Arrays; + import org.apache.maven.doxia.sink.Sink; import org.asciidoctor.ast.Document; import org.asciidoctor.ast.ListItem; @@ -12,9 +15,6 @@ import org.junit.jupiter.api.Test; import org.mockito.Mockito; -import java.io.StringWriter; -import java.util.Arrays; - import static org.asciidoctor.maven.site.parser.processors.test.ReflectionUtils.extractField; import static org.asciidoctor.maven.site.parser.processors.test.TestNodeProcessorFactory.createSink; import static org.assertj.core.api.Assertions.assertThat; @@ -122,6 +122,7 @@ void should_process_listing_node() { @Test void should_process_image_node() { StructuralNode mockNode = mockNode("image", BlockImpl.class); + Mockito.when(mockNode.getAttribute(Mockito.eq("target"))).thenReturn("image.png"); nodesSinker.processNode(mockNode); From f4e5142046a81824d3ffebc7bf72f364ebf40f13 Mon Sep 17 00:00:00 2001 From: Abel Salgado Romero Date: Thu, 10 Oct 2024 18:23:38 +0200 Subject: [PATCH 08/12] Style: remove Arrays.asList --- .../org/asciidoctor/maven/site/parser/NodeSinkerTest.java | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/NodeSinkerTest.java b/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/NodeSinkerTest.java index ece9f114..b616ff2a 100644 --- a/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/NodeSinkerTest.java +++ b/asciidoctor-parser-doxia-module/src/test/java/org/asciidoctor/maven/site/parser/NodeSinkerTest.java @@ -2,6 +2,7 @@ import java.io.StringWriter; import java.util.Arrays; +import java.util.List; import org.apache.maven.doxia.sink.Sink; import org.asciidoctor.ast.Document; @@ -72,7 +73,7 @@ void should_process_preamble_literal() { void should_process_preamble_node() { StructuralNode mockNode = mockNode("preamble"); StructuralNode literalBlock = mockNode("literal", BlockImpl.class); - Mockito.when(mockNode.getBlocks()).thenReturn(Arrays.asList(literalBlock)); + Mockito.when(mockNode.getBlocks()).thenReturn(List.of(literalBlock)); nodesSinker.processNode(mockNode); @@ -143,7 +144,7 @@ void should_process_ulist_node() { StructuralNode mockNode = mockNode("ulist", BlockImpl.class); ListItem mockListItem = mockNode("list_item", ListItem.class); Mockito.when(mockListItem.getMarker()).thenReturn("*"); - Mockito.when(mockNode.getBlocks()).thenReturn(Arrays.asList(mockListItem)); + Mockito.when(mockNode.getBlocks()).thenReturn(List.of(mockListItem)); nodesSinker.processNode(mockNode); @@ -155,7 +156,7 @@ void should_process_olist_node() { StructuralNode mockNode = mockNode("olist", BlockImpl.class); ListItem mockListItem = mockNode("list_item", ListItem.class); Mockito.when(mockListItem.getMarker()).thenReturn("."); - Mockito.when(mockNode.getBlocks()).thenReturn(Arrays.asList(mockListItem)); + Mockito.when(mockNode.getBlocks()).thenReturn(List.of(mockListItem)); nodesSinker.processNode(mockNode); From 6435e7d1d73348519c5d98cf2bf433d92f348135 Mon Sep 17 00:00:00 2001 From: Abel Salgado Romero Date: Thu, 10 Oct 2024 19:55:42 +0200 Subject: [PATCH 09/12] WIP: fixing site integration ITs --- asciidoctor-converter-doxia-module/pom.xml | 4 ++-- .../src/it/maven-site-plugin/src/site/site.xml | 2 +- .../src/it/maven-site-plugin/src/site/site.xml | 4 ++-- .../src/it/maven-site-plugin/validate.groovy | 10 +++++----- 4 files changed, 10 insertions(+), 10 deletions(-) diff --git a/asciidoctor-converter-doxia-module/pom.xml b/asciidoctor-converter-doxia-module/pom.xml index d2cca455..afe60bfc 100644 --- a/asciidoctor-converter-doxia-module/pom.xml +++ b/asciidoctor-converter-doxia-module/pom.xml @@ -12,8 +12,8 @@ asciidoctor-converter-doxia-module jar - Asciidoctor Converter Doxia Parser - Asciidoctor Doxia Parser based on Asciidoctor Html converter (for Maven Site integration) + Asciidoctor Converter Doxia Module + Asciidoctor Doxia Module based on Asciidoctor Html converter (for Maven Site integration) https://github.com/asciidoctor/asciidoctor-maven-plugin diff --git a/asciidoctor-converter-doxia-module/src/it/maven-site-plugin/src/site/site.xml b/asciidoctor-converter-doxia-module/src/it/maven-site-plugin/src/site/site.xml index 71ea0778..ddacea37 100644 --- a/asciidoctor-converter-doxia-module/src/it/maven-site-plugin/src/site/site.xml +++ b/asciidoctor-converter-doxia-module/src/it/maven-site-plugin/src/site/site.xml @@ -14,6 +14,6 @@ org.apache.maven.skins maven-fluido-skin - 1.12.0 + 2.0.0-M9 diff --git a/asciidoctor-parser-doxia-module/src/it/maven-site-plugin/src/site/site.xml b/asciidoctor-parser-doxia-module/src/it/maven-site-plugin/src/site/site.xml index 9ae5a719..8861f67c 100644 --- a/asciidoctor-parser-doxia-module/src/it/maven-site-plugin/src/site/site.xml +++ b/asciidoctor-parser-doxia-module/src/it/maven-site-plugin/src/site/site.xml @@ -7,11 +7,11 @@ - ${reports} + org.apache.maven.skins maven-fluido-skin - 1.12.0 + 2.0.0-M9 diff --git a/asciidoctor-parser-doxia-module/src/it/maven-site-plugin/validate.groovy b/asciidoctor-parser-doxia-module/src/it/maven-site-plugin/validate.groovy index 72bd2eaf..fedf3874 100644 --- a/asciidoctor-parser-doxia-module/src/it/maven-site-plugin/validate.groovy +++ b/asciidoctor-parser-doxia-module/src/it/maven-site-plugin/validate.groovy @@ -153,13 +153,13 @@ class HtmlAsserter { void containsSectionTitle(String value, int level) { def found = -1 - def id = value.replaceAll(" ", "_") + def id = value.toLowerCase().replaceAll(" ", "_") if (level == 2) { - found = find("

            $value

            ") + found = find("

            $value

            ") } else if (level == 3) { - found = find("

            $value

            ") + found = find("

            $value

            ") } else if (level == 4) { - found = find("

            $value

            ") + found = find("

            $value

            ") } assertFound("Section Title (level:$level)", value, found) } @@ -185,7 +185,7 @@ class HtmlAsserter { } void containsOrderedList(String... values) { - def found = find("
            1. ${values.join('
            2. ')}
            ") + def found = find("
            1. ${values.join('
            2. ')}
            ") assertFound("Ordered list", values.join(','), found) } From 03b2f9605ff99d7f0cdf5102f030f8fad14892c2 Mon Sep 17 00:00:00 2001 From: Abel Salgado Romero Date: Thu, 10 Oct 2024 22:28:55 +0200 Subject: [PATCH 10/12] Remove use of @Named,bean not recognized --- .../maven/site/parser/AsciidoctorAstDoxiaParser.java | 5 +++-- .../maven/site/parser/AsciidoctorAstDoxiaParserModule.java | 6 +++--- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/AsciidoctorAstDoxiaParser.java b/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/AsciidoctorAstDoxiaParser.java index 06a0fffa..23d077f4 100644 --- a/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/AsciidoctorAstDoxiaParser.java +++ b/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/AsciidoctorAstDoxiaParser.java @@ -1,7 +1,6 @@ package org.asciidoctor.maven.site.parser; import javax.inject.Inject; -import javax.inject.Named; import javax.inject.Provider; import java.io.File; import java.io.IOException; @@ -10,6 +9,7 @@ import org.apache.maven.doxia.parser.AbstractTextParser; import org.apache.maven.doxia.parser.ParseException; +import org.apache.maven.doxia.parser.Parser; import org.apache.maven.doxia.sink.Sink; import org.apache.maven.project.MavenProject; import org.asciidoctor.Asciidoctor; @@ -28,6 +28,7 @@ import org.asciidoctor.maven.site.SiteConversionConfiguration; import org.asciidoctor.maven.site.SiteConversionConfigurationParser; import org.asciidoctor.maven.site.SiteLogHandlerDeserializer; +import org.codehaus.plexus.component.annotations.Component; import org.codehaus.plexus.util.IOUtil; import org.codehaus.plexus.util.xml.Xpp3Dom; import org.slf4j.LoggerFactory; @@ -42,7 +43,7 @@ * @author abelsromero * @since 3.0.0 */ -@Named(AsciidoctorAstDoxiaParser.ROLE_HINT) +@Component(role = Parser.class, hint = AsciidoctorAstDoxiaParser.ROLE_HINT) public class AsciidoctorAstDoxiaParser extends AbstractTextParser { private final org.slf4j.Logger logger = LoggerFactory.getLogger(AsciidoctorAstDoxiaParser.class); diff --git a/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/AsciidoctorAstDoxiaParserModule.java b/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/AsciidoctorAstDoxiaParserModule.java index 1d1a7292..0ecd381d 100644 --- a/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/AsciidoctorAstDoxiaParserModule.java +++ b/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/AsciidoctorAstDoxiaParserModule.java @@ -1,8 +1,8 @@ package org.asciidoctor.maven.site.parser; -import javax.inject.Named; - import org.apache.maven.doxia.parser.module.AbstractParserModule; +import org.apache.maven.doxia.parser.module.ParserModule; +import org.codehaus.plexus.component.annotations.Component; /** * This class is the entry point for integration with the Maven Site Plugin @@ -13,7 +13,7 @@ * @author abelsromero * @since 3.0.0 */ -@Named(AsciidoctorAstDoxiaParser.ROLE_HINT) +@Component(role = ParserModule.class, hint = AsciidoctorAstDoxiaParser.ROLE_HINT) public class AsciidoctorAstDoxiaParserModule extends AbstractParserModule { /** From 3dedb2ac1ea728e7bea9dd80d7e048d42a6dd29c Mon Sep 17 00:00:00 2001 From: Abel Salgado Romero Date: Sat, 12 Oct 2024 21:29:51 +0200 Subject: [PATCH 11/12] Fix asciidoctor-parser-doxia-module --- .../src/it/maven-site-plugin/validate.groovy | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/asciidoctor-parser-doxia-module/src/it/maven-site-plugin/validate.groovy b/asciidoctor-parser-doxia-module/src/it/maven-site-plugin/validate.groovy index fedf3874..854b71d7 100644 --- a/asciidoctor-parser-doxia-module/src/it/maven-site-plugin/validate.groovy +++ b/asciidoctor-parser-doxia-module/src/it/maven-site-plugin/validate.groovy @@ -136,7 +136,7 @@ class HtmlAsserter { } void containsBreadcrumbs(String value) { - def found = find("
          3. ${value}
          4. ") + def found = find("
          5. ${value}
          6. ") assertFound("Breadcrumb", value, found) } From bb43f6d810ad4727e3d0daeea5a5f83efdd1b7e5 Mon Sep 17 00:00:00 2001 From: Abel Salgado Romero Date: Sat, 12 Oct 2024 23:14:07 +0200 Subject: [PATCH 12/12] Fix IT warnings --- CHANGELOG.adoc | 3 ++- .../src/it/maven-site-plugin/pom.xml | 1 + .../src/it/maven-site-plugin/src/site/site.xml | 6 ++++-- .../maven/site/AsciidoctorConverterDoxiaParser.java | 1 - .../src/it/maven-site-plugin/pom.xml | 1 + .../src/it/maven-site-plugin/src/site/site.xml | 6 ++++-- .../site-integration/pages/compatibility-matrix.adoc | 2 +- 7 files changed, 13 insertions(+), 7 deletions(-) diff --git a/CHANGELOG.adoc b/CHANGELOG.adoc index fd9c59ef..73c1e847 100644 --- a/CHANGELOG.adoc +++ b/CHANGELOG.adoc @@ -16,11 +16,12 @@ For a detailed view of what has changed, refer to the {uri-repo}/commits/main[co Bug Fixes:: * Fix open IMG tags in parser-doxia-module (#930) + * Fix naming in Asciidoctor Converter Doxia Module pom (#934) Improvements:: * Added support for AsciidoctorJ v3.0.0 (#651) - * Add compatibility with maven-site-plugin v3.20.0 (#934) + * Add compatibility with maven-site-plugin v3.20.0 and Doxia v2.0.0 (#933) Build / Infrastructure:: diff --git a/asciidoctor-converter-doxia-module/src/it/maven-site-plugin/pom.xml b/asciidoctor-converter-doxia-module/src/it/maven-site-plugin/pom.xml index 139ab88b..5eb993db 100644 --- a/asciidoctor-converter-doxia-module/src/it/maven-site-plugin/pom.xml +++ b/asciidoctor-converter-doxia-module/src/it/maven-site-plugin/pom.xml @@ -51,6 +51,7 @@ 2 + false **/_*.adoc,**/_*/ diff --git a/asciidoctor-converter-doxia-module/src/it/maven-site-plugin/src/site/site.xml b/asciidoctor-converter-doxia-module/src/it/maven-site-plugin/src/site/site.xml index ddacea37..a660f79d 100644 --- a/asciidoctor-converter-doxia-module/src/it/maven-site-plugin/src/site/site.xml +++ b/asciidoctor-converter-doxia-module/src/it/maven-site-plugin/src/site/site.xml @@ -1,4 +1,6 @@ - + @@ -16,4 +18,4 @@ maven-fluido-skin 2.0.0-M9 - + diff --git a/asciidoctor-converter-doxia-module/src/main/java/org/asciidoctor/maven/site/AsciidoctorConverterDoxiaParser.java b/asciidoctor-converter-doxia-module/src/main/java/org/asciidoctor/maven/site/AsciidoctorConverterDoxiaParser.java index 835a6118..bfc90b94 100644 --- a/asciidoctor-converter-doxia-module/src/main/java/org/asciidoctor/maven/site/AsciidoctorConverterDoxiaParser.java +++ b/asciidoctor-converter-doxia-module/src/main/java/org/asciidoctor/maven/site/AsciidoctorConverterDoxiaParser.java @@ -108,7 +108,6 @@ private MemoryLogHandler asciidoctorLoggingSetup(Asciidoctor asciidoctor, LogHan logRecord -> logger.info(LogRecordFormatter.format(logRecord, siteDirectory))); asciidoctor.registerLogHandler(memoryLogHandler); // disable default console output of AsciidoctorJ - // TODO validate if still needed java.util.logging.Logger.getLogger("asciidoctor").setUseParentHandlers(false); return memoryLogHandler; } diff --git a/asciidoctor-parser-doxia-module/src/it/maven-site-plugin/pom.xml b/asciidoctor-parser-doxia-module/src/it/maven-site-plugin/pom.xml index d78941ac..d4c1b095 100644 --- a/asciidoctor-parser-doxia-module/src/it/maven-site-plugin/pom.xml +++ b/asciidoctor-parser-doxia-module/src/it/maven-site-plugin/pom.xml @@ -31,6 +31,7 @@ 2 + false **/_*.adoc,**/_*/ diff --git a/asciidoctor-parser-doxia-module/src/it/maven-site-plugin/src/site/site.xml b/asciidoctor-parser-doxia-module/src/it/maven-site-plugin/src/site/site.xml index 8861f67c..c401710d 100644 --- a/asciidoctor-parser-doxia-module/src/it/maven-site-plugin/src/site/site.xml +++ b/asciidoctor-parser-doxia-module/src/it/maven-site-plugin/src/site/site.xml @@ -1,4 +1,6 @@ - + @@ -14,4 +16,4 @@ maven-fluido-skin 2.0.0-M9 - + diff --git a/docs/modules/site-integration/pages/compatibility-matrix.adoc b/docs/modules/site-integration/pages/compatibility-matrix.adoc index 89fbeaa5..ef236cbd 100644 --- a/docs/modules/site-integration/pages/compatibility-matrix.adoc +++ b/docs/modules/site-integration/pages/compatibility-matrix.adoc @@ -11,7 +11,7 @@ Versions not listed below are not supported, please consider upgrading. |Asciidoctor Doxia Module | Maven Site Plugin | Supported |v3.0.x -|v3.12.x +|v3.1x.x ~ v3.12.x |Yes |v3.1.x