Skip to content

Commit a3266ed

Browse files
authored
feat(site): Migrated the website to use Antora. (apache#1880)
* fix(website): Carosuel Height and Bootstrap 5 mods * feat(website): Migrate to Antora * fix(website): Include site build in maven site phase * fix(website): Include site build in maven site phase * fix(website): Fixed viewport on landing page * fix(website): Created a separate module website instead of using the src * fix(website): Remove lost building.html file * fix(website): Update headers * fix(website): Update gitignore * fix(website): Update favicon.ico * fix(website): Update Jenkinsfile
1 parent 0ad7a7b commit a3266ed

File tree

342 files changed

+6952
-4126
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

342 files changed

+6952
-4126
lines changed

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -214,3 +214,5 @@ DartConfiguration.tcl
214214
/plc4c/.idea/codeStyles/codeStyleConfig.xml
215215
/plc4c/.idea/codeStyles/Project.xml
216216
/plc4c/.idea/.name
217+
218+
/website/node_modules/

Jenkinsfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ pipeline {
182182
// Generate the driver documentation.
183183
sh './mvnw -P${JENKINS_PROFILE},with-java,skip-prerequisite-check site -X -pl :plc4j-driver-all'
184184
// Build the actual website.
185-
sh './mvnw -P${JENKINS_PROFILE},skip-prerequisite-check site -X -pl .'
185+
sh './mvnw -P${JENKINS_PROFILE},skip-prerequisite-check site -X -pl . -pl website'
186186
}
187187
}
188188

@@ -196,7 +196,7 @@ pipeline {
196196
//sh './mvnw -B -P${JENKINS_PROFILE},skip-prerequisite-check,with-proxies site:stage'
197197
sh './mvnw -B -P${JENKINS_PROFILE},skip-prerequisite-check site:stage -pl .'
198198
// Make sure the script is executable.
199-
sh 'chmod +x tools/clean-site.sh'
199+
//sh 'chmod +x tools/clean-site.sh'
200200
// Remove some redundant resources, which shouldn't be required.
201201
//sh 'tools/clean-site.sh'
202202
// Stash the generated site so we can publish it on the 'git-website' node.

plc4j/drivers/all/src/site/groovy/generate-config-documentation.groovy

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ def plcDriverManager = new DefaultPlcDriverManager(moduleClassloader)
5656

5757
// Process all driver information.
5858
for (final def protocolCode in plcDriverManager.getProtocolCodes()) {
59-
def outputFile = new File(project.getBasedir(), "src/site/generated/" + protocolCode + ".adoc")
59+
def outputFile = new File(project.getBasedir(), "../../../website/generated/" + protocolCode + ".adoc")
6060
// In order to re-generate this file, make sure it doesn't exist.
6161
if(outputFile.exists()) {
6262
outputFile.delete()

pom.xml

Lines changed: 8 additions & 87 deletions
Original file line numberDiff line numberDiff line change
@@ -172,6 +172,7 @@
172172
<modules>
173173
<!-- Definition of the protocol message formats -->
174174
<module>protocols</module>
175+
<module>website</module>
175176
</modules>
176177

177178
<dependencyManagement>
@@ -644,7 +645,7 @@
644645
</goals>
645646
<inherited>false</inherited>
646647
<configuration>
647-
<source>${project.basedir}/src/main/script/prerequisiteCheck.groovy</source>
648+
<source>${project.basedir}/website/main/script/prerequisiteCheck.groovy</source>
648649
</configuration>
649650
</execution>
650651
<!--
@@ -658,7 +659,7 @@
658659
<goal>execute</goal>
659660
</goals>
660661
<configuration>
661-
<source>${project.basedir}/src/main/script/preSiteGeneration.groovy</source>
662+
<source>${project.basedir}/website/main/script/preSiteGeneration.groovy</source>
662663
</configuration>
663664
</execution>
664665
</executions>
@@ -976,55 +977,6 @@
976977
977978
-->
978979

979-
<plugin>
980-
<groupId>org.apache.maven.plugins</groupId>
981-
<artifactId>maven-resources-plugin</artifactId>
982-
<executions>
983-
<execution>
984-
<id>copy-site-resources</id>
985-
<!-- Only execute this for the parent module -->
986-
<inherited>false</inherited>
987-
<phase>pre-site</phase>
988-
<goals>
989-
<goal>copy-resources</goal>
990-
</goals>
991-
<configuration>
992-
<outputDirectory>${project.build.directory}/site</outputDirectory>
993-
<resources>
994-
<resource>
995-
<directory>${project.basedir}/src/site/resources-filtered</directory>
996-
<filtering>true</filtering>
997-
<targetPath>${project.build.directory}/site</targetPath>
998-
</resource>
999-
</resources>
1000-
</configuration>
1001-
</execution>
1002-
<!--
1003-
Copy the schemas that might be distributed throughout the codebase to a central "schemas"
1004-
directory so IDEs can automatically pull them in.
1005-
-->
1006-
<execution>
1007-
<id>copy-schemas</id>
1008-
<!-- Only execute this for the parent module -->
1009-
<inherited>false</inherited>
1010-
<phase>pre-site</phase>
1011-
<goals>
1012-
<goal>copy-resources</goal>
1013-
</goals>
1014-
<configuration>
1015-
<outputDirectory>${project.build.directory}/site</outputDirectory>
1016-
<resources>
1017-
<!-- Copy the resources for the test-suites -->
1018-
<resource>
1019-
<directory>${project.basedir}/plc4j/utils/test-utils/src/main/resources/schemas</directory>
1020-
<targetPath>${project.build.directory}/site/schemas</targetPath>
1021-
</resource>
1022-
</resources>
1023-
</configuration>
1024-
</execution>
1025-
</executions>
1026-
</plugin>
1027-
1028980
<!--
1029981
Make the maven-site-plugin stage the output in the "asf-site" branch
1030982
-->
@@ -1266,48 +1218,17 @@
12661218
generating output.
12671219
-->
12681220
<version>3.12.1</version>
1221+
12691222
<configuration>
12701223
<!--templateFile>${session.executionRootDirectory}/src/site/template/site.vm</templateFile-->
12711224
<generateReports>false</generateReports>
1272-
<generateSitemap>true</generateSitemap>
1225+
<generateSitemap>false</generateSitemap>
12731226
<relativizeDecorationLinks>false</relativizeDecorationLinks>
12741227
<locales>en</locales>
12751228
<inputEncoding>${project.build.sourceEncoding}</inputEncoding>
12761229
<outputEncoding>${project.reporting.outputEncoding}</outputEncoding>
1277-
<!--
1278-
IntelliJ can't find the asciidoc config option in the site plugin, which is correct.
1279-
However, this config section is used by the asciidoctor site plugin extension. So please
1280-
ignore this error, it's actually ok.
1281-
-->
1282-
<asciidoc>
1283-
<attributes>
1284-
<source-highlighter>prettify</source-highlighter>
1285-
<imagesoutdir>${project.build.directory}/site/images</imagesoutdir>
1286-
<pom-adoc>${project.build.directory}/pom.adoc</pom-adoc>
1287-
</attributes>
1288-
<requires>
1289-
<require>asciidoctor-diagram</require>
1290-
</requires>
1291-
</asciidoc>
1230+
12921231
</configuration>
1293-
<dependencies>
1294-
<!-- Add support for asciidoctor -->
1295-
<dependency>
1296-
<groupId>org.asciidoctor</groupId>
1297-
<artifactId>asciidoctor-maven-plugin</artifactId>
1298-
<version>${asciidoctor.maven.plugin.version}</version>
1299-
</dependency>
1300-
<dependency>
1301-
<groupId>org.asciidoctor</groupId>
1302-
<artifactId>asciidoctorj</artifactId>
1303-
<version>${asciidoctorj.version}</version>
1304-
</dependency>
1305-
<dependency>
1306-
<groupId>org.asciidoctor</groupId>
1307-
<artifactId>asciidoctorj-diagram</artifactId>
1308-
<version>${asciidoctorj.diagram.version}</version>
1309-
</dependency>
1310-
</dependencies>
13111232
</plugin>
13121233

13131234
<plugin>
@@ -1723,7 +1644,7 @@
17231644
Please don't change "target" to "${project.build.directory}" as profile-activation happens before
17241645
property resolution ... it won't work with a property.
17251646
-->
1726-
<exists>src/main/generated/</exists>
1647+
<exists>website/main/generated/</exists>
17271648
</file>
17281649
</activation>
17291650
<build>
@@ -1740,7 +1661,7 @@
17401661
</goals>
17411662
<configuration>
17421663
<sources>
1743-
<source>${project.basedir}/src/main/generated/</source>
1664+
<source>${project.basedir}/website/main/generated/</source>
17441665
</sources>
17451666
</configuration>
17461667
</execution>

0 commit comments

Comments
 (0)