remove unused asciidoc plugin and docs

This commit is contained in:
Mark Pollack
2023-12-04 14:49:16 -05:00
parent ac9ae589f4
commit 27bb72999a
20 changed files with 17 additions and 401 deletions

View File

@@ -32,7 +32,7 @@ jobs:
- name: Generate Reference docs
working-directory: spring-ai-docs
run: mvn site
run: mvn assembly:single
- name: Capture project version
run: echo PROJECT_VERSION=$(mvn help:evaluate -Dexpression=project.version --quiet -DforceStdout) >> $GITHUB_ENV

View File

@@ -252,11 +252,6 @@
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-site-plugin</artifactId>
<version>${maven-site-plugin.version}</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-deploy-plugin</artifactId>

View File

@@ -41,124 +41,17 @@
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.asciidoctor</groupId>
<artifactId>asciidoctor-maven-plugin</artifactId>
<version>${asciidoctor-maven-plugin.version}</version>
<dependencies>
<dependency>
<groupId>org.asciidoctor</groupId>
<artifactId>asciidoctorj-pdf</artifactId>
<version>${asciidoctorj-pdf.version}</version>
</dependency>
<dependency>
<groupId>org.asciidoctor</groupId>
<artifactId>asciidoctorj-epub3</artifactId>
<version>${asciidoctorj-epub.version}</version>
</dependency>
<dependency>
<groupId>io.spring.asciidoctor.backends</groupId>
<artifactId>spring-asciidoctor-backends</artifactId>
<version>${spring-asciidoctor-backends.version}</version>
</dependency>
</dependencies>
<configuration>
<sourceDirectory>${project.basedir}/src/main/asciidoc</sourceDirectory>
<outputDirectory>${project.build.directory}/asciidoc</outputDirectory>
</configuration>
<executions>
<execution>
<id>generate-html</id>
<phase>site</phase>
<goals>
<goal>process-asciidoc</goal>
</goals>
<configuration>
<backend>spring-html</backend>
<doctype>book</doctype>
<attributes>
<docinfodir>${project.build.directory}/asciidoc</docinfodir>
<docinfo>shared</docinfo>
<stylesdir>css/</stylesdir>
<stylesheet>site.css</stylesheet>
<linkcss>true</linkcss>
<icons>font</icons>
<sectanchors />
<source-highlighter>highlight.js</source-highlighter>
<highlightjsdir>js/highlight</highlightjsdir>
<highlightjs-theme>github</highlightjs-theme>
<idprefix />
<idseparator>-</idseparator>
<spring-version>${project.version}</spring-version>
<revnumber>${project.version}</revnumber>
<allow-uri-read />
</attributes>
</configuration>
</execution>
<execution>
<id>generate-pdf</id>
<phase>site</phase>
<goals>
<goal>process-asciidoc</goal>
</goals>
<configuration>
<backend>pdf</backend>
<doctype>book</doctype>
<attributes>
<icons>font</icons>
<pagenums />
<sectnums />
<sectanchors />
<toc />
<source-highlighter>coderay</source-highlighter>
<project-version>${project.version}</project-version>
<revnumber>${project.version}</revnumber>
</attributes>
</configuration>
</execution>
<execution>
<id>generate-epub</id>
<phase>site</phase>
<goals>
<goal>process-asciidoc</goal>
</goals>
<configuration>
<backend>epub3</backend>
<doctype>book</doctype>
<attributes>
<icons>font</icons>
<pagenums />
<sectnums />
<sectanchors />
<toc />
<source-highlighter>coderay</source-highlighter>
<project-version>${project.version}</project-version>
<revnumber>${project.version}</revnumber>
</attributes>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-assembly-plugin</artifactId>
<version>${maven-assembly-plugin.version}</version>
<configuration>
<descriptors>
<descriptor>src/assembly/docs.xml</descriptor>
<descriptor>src/assembly/javadocs.xml</descriptor>
</descriptors>
<finalName>spring-ai-${project.version}</finalName>
<appendAssemblyId>true</appendAssemblyId>
</configuration>
<executions>
<execution>
<id>create-distribution</id>
<phase>site</phase>
<goals>
<goal>single</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>

View File

@@ -1,38 +0,0 @@
<assembly xmlns="http://maven.apache.org/ASSEMBLY/2.1.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/ASSEMBLY/2.1.0 http://maven.apache.org/xsd/assembly-2.1.0.xsd">
<id>docs</id>
<formats>
<format>zip</format>
</formats>
<includeBaseDirectory>false</includeBaseDirectory>
<fileSets>
<fileSet>
<directory>target/asciidoc</directory>
<outputDirectory>reference/html</outputDirectory>
<includes>
<include>css/*.*</include>
<include>images/*.*</include>
<include>img/*.*</include>
<include>js/**/*.*</include>
<include>*.html</include>
</includes>
</fileSet>
<fileSet>
<directory>../target/site/apidocs</directory>
<outputDirectory>api</outputDirectory>
</fileSet>
</fileSets>
<files>
<file>
<source>target/asciidoc/index-single.pdf</source>
<destName>spring-ai-reference.pdf</destName>
<outputDirectory>reference/pdf</outputDirectory>
</file>
<file>
<source>target/asciidoc/index-single.epub</source>
<destName>spring-ai-reference.epub</destName>
<outputDirectory>reference/epub</outputDirectory>
</file>
</files>
</assembly>

View File

@@ -0,0 +1,15 @@
<assembly xmlns="http://maven.apache.org/ASSEMBLY/2.1.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/ASSEMBLY/2.1.0 http://maven.apache.org/xsd/assembly-2.1.0.xsd">
<id>docs</id>
<formats>
<format>zip</format>
</formats>
<includeBaseDirectory>false</includeBaseDirectory>
<fileSets>
<fileSet>
<directory>../target/site/apidocs</directory>
<outputDirectory>api</outputDirectory>
</fileSet>
</fileSets>
</assembly>

View File

@@ -1,15 +0,0 @@
:toc: left
:toclevels: 4
[[configureClient]]
== Configuring an `AiClient`
include::attributes.adoc[]
TBD
[[usingAiClient]]
=== Using AiClient
TBD

View File

@@ -1 +0,0 @@
:ai-asciidoc: ./

View File

@@ -1,19 +0,0 @@
:toc: left
:toclevels: 4
[[domainLanguageOfAi]]
== The Domain Language of AI
include::attributes.adoc[]
TBD
=== Prompt
TBD
==== AiClient
TBD

View File

@@ -1,9 +0,0 @@
'''
Mark Pollack
Copyright © 2023 VMware, Inc. All Rights Reserved.
Copies of this document may be made for your own use and for
distribution to others, provided that you do not charge any fee for such
copies and further provided that each copy contains this Copyright
Notice, whether distributed in print or electronically.

View File

@@ -1,6 +0,0 @@
[[glossary]]
[appendix]
== Glossary
[glossary]
=== Spring AI Glossary

View File

@@ -1 +0,0 @@
= Spring AI - Reference Documentation

View File

@@ -1,20 +0,0 @@
:doctype: book
:toc: left
:toclevels: 4
:sectnums:
include::attributes.adoc[]
include::header/index-header.adoc[]
include::toggle.adoc[]
include::spring-ai-intro.adoc[]
include::domain.adoc[]
include::prompt.adoc[]
include::aiclient.adoc[]
include::glossary.adoc[]

View File

@@ -1,27 +0,0 @@
include::attributes.adoc[]
include::header/index-header.adoc[]
// ======================================================================================
This documentation is also available
as a link:index-single.html[single HTML file] and as link:../pdf/spring-ai-reference.pdf[PDF]
and link:../epub/spring-ai-reference.epub[EPUB] documents.
The reference documentation is divided into several sections:
[horizontal]
<<spring-ai-intro.adoc#spring-ai-intro,Spring AI Introduction>> :: Background, usage
scenarios, and general guidelines.
<<domain.adoc#domainLanguageOfAi,The Domain Language of AI>> :: Core concepts and abstractions
of the AI domain language.
<<prompt.adoc#createPrompt,Creating a Prompt>> :: Prompt creation.
<<aiclient.adoc#configureClient,Configuring an AiClient>> :: AiClient configuration and execution.
The following appendices are available:
[horizontal]
<<glossary.adoc#glossary,Glossary>> :: Glossary of common terms, concepts, and vocabulary of
the AI domain.
include::footer/index-footer.adoc[]

View File

@@ -1,76 +0,0 @@
$(document).ready(function(){
var BATCH_LANGUAGES = ["java", "xml", "both"];
var $xmlButton = $("#xmlButton");
var $javaButton = $("#javaButton");
var $bothButton = $("#bothButton");
var $xmlContent = $("*.xmlContent");
var $xmlContentAll = $("*.xmlContent > *");
var $javaContent = $("*.javaContent");
var $javaContentAll = $("*.javaContent > *");
// Initial cookie handler. This part remembers the
// reader's choice and sets the toggle accordingly.
var lang = window.localStorage.getItem("docToggle");
if (BATCH_LANGUAGES.indexOf(lang) === -1) {
lang = "java";
$javaButton.prop("checked", true);
setJava();
} else {
if (lang === "xml") {
$xmlButton.prop("checked", true);
setXml();
}
if (lang === "java") {
$javaButton.prop("checked", true);
setJava();
}
if (lang === "both") {
$javaButton.prop("checked", true);
setBoth();
}
}
// Click handlers
$xmlButton.on("click", function() {
setXml();
});
$javaButton.on("click", function() {
setJava();
});
$bothButton.on("click", function() {
setBoth();
});
// Functions to do the work of handling the reader's choice, whether through a click
// or through a cookie. 3652 days is 10 years, give or take a leap day.
function setXml() {
$xmlContent.show();
$javaContent.hide();
$javaContentAll.addClass("js-toc-ignore");
$xmlContentAll.removeClass("js-toc-ignore");
window.dispatchEvent(new Event("tocRefresh"));
window.localStorage.setItem('docToggle', 'xml');
}
function setJava() {
$javaContent.show();
$xmlContent.hide();
$xmlContentAll.addClass("js-toc-ignore");
$javaContentAll.removeClass("js-toc-ignore");
window.dispatchEvent(new Event("tocRefresh"));
window.localStorage.setItem('docToggle', 'java');
}
function setBoth() {
$javaContent.show();
$xmlContent.show();
$javaContentAll.removeClass("js-toc-ignore");
$xmlContentAll.removeClass("js-toc-ignore");
window.dispatchEvent(new Event("tocRefresh"));
window.localStorage.setItem('docToggle', 'both');
}
});

File diff suppressed because one or more lines are too long

View File

@@ -1,9 +0,0 @@
:toc: left
:toclevels: 4
[[createPrompt]]
== Creating a Prompt
include::attributes.adoc[]
TBD

View File

@@ -1,47 +0,0 @@
:toc: left
:toclevels: 4
include::attributes.adoc[]
ifdef::backend-spring-html[]
This documentation is also available
as link:index.html[multiple HTML files] and as link:../pdf/spring-ai-reference.pdf[PDF]
and link:../epub/spring-ai-reference.epub[EPUB] documents.
endif::[]
ifdef::backend-pdf[]
This documentation is also available
as link:index.html[multiple HTML files], a link:index-single.html[single HTML file],
and an link:../epub/spring-ai-reference.epub[EPUB] document.
endif::[]
ifdef::backend-epub3[]
This documentation is also available
as link:index.html[multiple HTML files], a link:index-single.html[single HTML file],
and a link:../pdf/spring-ai-reference.pdf[PDF] document.
endif::[]
[[spring-ai-intro]]
== Spring AI Introduction
TBD
[[springAiBackground]]
=== Background
TBD
[[springAiUsageScenarios]]
=== Usage Scenarios
TBD
==== Business Scenarios
TBD
==== Technical Objectives
TBD

View File

@@ -1,15 +0,0 @@
ifdef::backend-spring-html[]
+++
<div>
<script type="text/javascript" src="js/jquery-3.2.1.min.js"></script>
<script type="text/javascript" src="js/js.cookie.js"></script>
<script type="text/javascript" src="js/DocumentToggle.js"></script>
<script type="text/javascript" src="js/Redirect.js"></script>
<div class="docToggle-button">
<input id="xmlButton" type="radio" name="docToggle" value="XML"><label for="xmlButton">XML</label>
<input id="javaButton" type="radio" name="docToggle" value="Java" checked><label for="javaButton">Java</label>
<input id="bothButton" type="radio" name="docToggle" value="Both" checked><label for="bothButton">Both</label>
</div>
</div>
+++
endif::backend-spring-html[]