From 5f2a0f571cdc9edff35a5da73c127f5b32e5a136 Mon Sep 17 00:00:00 2001 From: John Dallaway Date: Thu, 11 Jul 2024 14:03:27 +0100 Subject: [PATCH] Example AsciiDoc content --- .../.asciidoctorconfig.adoc | 13 +++++++++++ doc/org.eclipse.cdt.doc.user/.gitignore | 1 + doc/org.eclipse.cdt.doc.user/build.properties | 3 ++- doc/org.eclipse.cdt.doc.user/pom.xml | 23 +++++++++++++++++++ .../src/asciidoc/example.adoc | 8 +++++++ 5 files changed, 47 insertions(+), 1 deletion(-) create mode 100644 doc/org.eclipse.cdt.doc.user/.asciidoctorconfig.adoc create mode 100644 doc/org.eclipse.cdt.doc.user/src/asciidoc/example.adoc diff --git a/doc/org.eclipse.cdt.doc.user/.asciidoctorconfig.adoc b/doc/org.eclipse.cdt.doc.user/.asciidoctorconfig.adoc new file mode 100644 index 00000000000..6b08333d331 --- /dev/null +++ b/doc/org.eclipse.cdt.doc.user/.asciidoctorconfig.adoc @@ -0,0 +1,13 @@ +// +++++++++++++++++++++++++++++++++++++++++++++++++++++++ +// + Initial AsciiDoc editor configuration file - V1.0 + +// ++++++++++++++++++++++++++++++++++++++++++++++++++++++ +// +// Did not find any configuration files, so creating this at project root level. +// If you do not like those files to be generated - you can turn it off inside Asciidoctor Editor preferences. +// +// You can define editor specific parts here. +// For example: with next line you could set imagesdir attribute to subfolder "images" relative to the folder where this config file is located. +// :imagesdir: {asciidoctorconfigdir}/images +// +// For more information please take a look at https://github.com/de-jcup/eclipse-asciidoctor-editor/wiki/Asciidoctor-configfiles +:imagesdir: {asciidoctorconfigdir}/images diff --git a/doc/org.eclipse.cdt.doc.user/.gitignore b/doc/org.eclipse.cdt.doc.user/.gitignore index 9e440c00d03..7cb3f4e9213 100644 --- a/doc/org.eclipse.cdt.doc.user/.gitignore +++ b/doc/org.eclipse.cdt.doc.user/.gitignore @@ -1 +1,2 @@ +/html/ /workspace/ diff --git a/doc/org.eclipse.cdt.doc.user/build.properties b/doc/org.eclipse.cdt.doc.user/build.properties index 2e45cd9125c..1b93f454f7c 100644 --- a/doc/org.eclipse.cdt.doc.user/build.properties +++ b/doc/org.eclipse.cdt.doc.user/build.properties @@ -38,7 +38,8 @@ bin.includes = about.html,\ intro/,\ notices.html,\ book.css,\ - index*/ + index*/,\ + html/ bin.excludes = build.properties,\ customBuildCallbacks.xml diff --git a/doc/org.eclipse.cdt.doc.user/pom.xml b/doc/org.eclipse.cdt.doc.user/pom.xml index a9cc1cb8bbd..4da0311f539 100644 --- a/doc/org.eclipse.cdt.doc.user/pom.xml +++ b/doc/org.eclipse.cdt.doc.user/pom.xml @@ -40,6 +40,29 @@ + + org.asciidoctor + asciidoctor-maven-plugin + 3.0.0 + + + adoc-to-html + generate-resources + + process-asciidoc + + + ${project.basedir}/html + + font + ../images + coderay + macro + + + + + diff --git a/doc/org.eclipse.cdt.doc.user/src/asciidoc/example.adoc b/doc/org.eclipse.cdt.doc.user/src/asciidoc/example.adoc new file mode 100644 index 00000000000..fbce9bb1111 --- /dev/null +++ b/doc/org.eclipse.cdt.doc.user/src/asciidoc/example.adoc @@ -0,0 +1,8 @@ +ifdef::env-github[] +:imagesdir: https://raw.githubusercontent.com/eclipse-cdt/cdt/main/doc/org.eclipse.cdt.doc.user/images +endif::[] + +=== Example document +Example image: + +image:search.png[Search dialog]