|
@@ -0,0 +1,171 @@
|
|
|
+<?xml version="1.0" encoding="UTF-8"?>
|
|
|
+<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/xsd/maven-4.0.0.xsd">
|
|
|
+ <modelVersion>4.0.0</modelVersion>
|
|
|
+
|
|
|
+ <groupId>org.shoulder.specs</groupId>
|
|
|
+ <artifactId>doc</artifactId>
|
|
|
+ <version>0.0.1-SNAPSHOT</version>
|
|
|
+
|
|
|
+ <properties>
|
|
|
+ <maven.build.timestamp.format>yyyy-MM-dd HH</maven.build.timestamp.format>
|
|
|
+ <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
|
|
+ <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
|
|
|
+ <maven.compiler.encoding>UTF-8</maven.compiler.encoding>
|
|
|
+ <maven.compiler.source>11</maven.compiler.source>
|
|
|
+ <maven.compiler.target>11</maven.compiler.target>
|
|
|
+
|
|
|
+ <asciidoctor-maven-plugin.version>2.0.0-RC.1</asciidoctor-maven-plugin.version>
|
|
|
+
|
|
|
+ <asciidoctorj.version>2.3.1</asciidoctorj.version>
|
|
|
+ <asciidoctorj-diagram.version>2.0.2</asciidoctorj-diagram.version>
|
|
|
+ <asciidoctorj-pdf.version>1.5.3</asciidoctorj-pdf.version>
|
|
|
+ <jruby.version>9.2.11.1</jruby.version>
|
|
|
+
|
|
|
+ </properties>
|
|
|
+
|
|
|
+ <organization>
|
|
|
+ <name>shoulder</name>
|
|
|
+ </organization>
|
|
|
+
|
|
|
+ <build>
|
|
|
+ <!-- https://github.com/asciidoctor/asciidoctor-maven-examples -->
|
|
|
+ <!-- https://github.com/asciidoctor/asciidoctor-maven-plugin/blob/master/README_zh-CN.adoc -->
|
|
|
+ <!-- 默认命令,配置后可以直接使用mvn编译(mvn clean process-asciidoc) 2000 端口开发访问 mvn asciidoctor:http -->
|
|
|
+ <!--mvn generate-resources -Dasciidoctor.attributes=toc=right-->
|
|
|
+ <defaultGoal>process-resources</defaultGoal>
|
|
|
+ <resources>
|
|
|
+ <resource>
|
|
|
+ <directory>src/main/resources</directory>
|
|
|
+ <targetPath>${project.build.directory}/book</targetPath>
|
|
|
+ </resource>
|
|
|
+ </resources>
|
|
|
+ <plugins>
|
|
|
+ <plugin>
|
|
|
+ <groupId>org.asciidoctor</groupId>
|
|
|
+ <artifactId>asciidoctor-maven-plugin</artifactId>
|
|
|
+ <version>${asciidoctor-maven-plugin.version}</version>
|
|
|
+ <configuration>
|
|
|
+ <outputDirectory>${project.build.directory}/shoulder-specs/${project.version}</outputDirectory>
|
|
|
+ <!--<sourceDocumentName>book.adoc</sourceDocumentName>
|
|
|
+ <imagesDir>./</imagesDir>-->
|
|
|
+ <preserveDirectories>false</preserveDirectories>
|
|
|
+ <!--<sourceDirectory>src/docs/asciidoc/generated</sourceDirectory>-->
|
|
|
+ <attributes>
|
|
|
+ <endpoint-url>http://example.org</endpoint-url>
|
|
|
+ <sourcedir>${project.build.sourceDirectory}</sourcedir>
|
|
|
+ <project-version>${project.version}</project-version>
|
|
|
+ </attributes>
|
|
|
+ <requires>
|
|
|
+ <require>asciidoctor-diagram</require>
|
|
|
+ </requires>
|
|
|
+ </configuration>
|
|
|
+ <executions>
|
|
|
+ <!--html-->
|
|
|
+ <execution>
|
|
|
+ <id>output-html</id>
|
|
|
+ <phase>generate-resources</phase>
|
|
|
+ <goals>
|
|
|
+ <goal>process-asciidoc</goal>
|
|
|
+ </goals>
|
|
|
+ <configuration>
|
|
|
+ <backend>html5</backend>
|
|
|
+ <!-- coderay prettify -->
|
|
|
+ <sourceHighlighter>coderay</sourceHighlighter>
|
|
|
+ <attributes>
|
|
|
+ <imagesdir>./images</imagesdir>
|
|
|
+ <toc>left</toc>
|
|
|
+ <icons>font</icons>
|
|
|
+ <sectanchors>true</sectanchors>
|
|
|
+ <!-- set the idprefix to blank -->
|
|
|
+ <idprefix/>
|
|
|
+ <idseparator>-</idseparator>
|
|
|
+ <docinfo1>true</docinfo1>
|
|
|
+ <revnumber>${project.version}</revnumber>
|
|
|
+ <revdate>${maven.build.timestamp}</revdate>
|
|
|
+ <organization>${project.organization.name}</organization>
|
|
|
+ </attributes>
|
|
|
+ </configuration>
|
|
|
+ </execution>
|
|
|
+ <!--pdf generator-->
|
|
|
+ <!--<execution>
|
|
|
+ <id>output-pdf</id>
|
|
|
+ <phase>generate-resources</phase>
|
|
|
+ <goals>
|
|
|
+ <goal>process-asciidoc</goal>
|
|
|
+ </goals>
|
|
|
+ <configuration>
|
|
|
+ <backend>pdf</backend>
|
|
|
+ <sourceHighlighter>coderay</sourceHighlighter>
|
|
|
+ <doctype>book</doctype>
|
|
|
+ <attributes>
|
|
|
+ <icons>font</icons>
|
|
|
+ <pagenums/>
|
|
|
+ <toc/>
|
|
|
+ <idprefix/>
|
|
|
+ <idseparator>-</idseparator>
|
|
|
+ <pdf-fontsdir>data/fonts</pdf-fontsdir>
|
|
|
+ <pdf-stylesdir>data/themes</pdf-stylesdir>
|
|
|
+ <pdf-style>cn</pdf-style>
|
|
|
+ </attributes>
|
|
|
+ </configuration>
|
|
|
+ </execution>-->
|
|
|
+ </executions>
|
|
|
+ <dependencies>
|
|
|
+ <!-- Comment this section to use the default jruby artifact provided by the plugin -->
|
|
|
+ <dependency>
|
|
|
+ <groupId>org.jruby</groupId>
|
|
|
+ <artifactId>jruby-complete</artifactId>
|
|
|
+ <version>${jruby.version}</version>
|
|
|
+ </dependency>
|
|
|
+ <!-- Comment this section to use the default AsciidoctorJ artifact provided by the plugin -->
|
|
|
+ <dependency>
|
|
|
+ <groupId>org.asciidoctor</groupId>
|
|
|
+ <artifactId>asciidoctorj</artifactId>
|
|
|
+ <version>${asciidoctorj.version}</version>
|
|
|
+ </dependency>
|
|
|
+ <dependency>
|
|
|
+ <groupId>org.asciidoctor</groupId>
|
|
|
+ <artifactId>asciidoctorj-diagram</artifactId>
|
|
|
+ <version>${asciidoctorj-diagram.version}</version>
|
|
|
+ </dependency>
|
|
|
+ <dependency>
|
|
|
+ <groupId>org.asciidoctor</groupId>
|
|
|
+ <artifactId>asciidoctorj-pdf</artifactId>
|
|
|
+ <version>${asciidoctorj-pdf.version}</version>
|
|
|
+ </dependency>
|
|
|
+ </dependencies>
|
|
|
+ </plugin>
|
|
|
+
|
|
|
+
|
|
|
+ <!--打包插件-->
|
|
|
+ <!--<plugin>
|
|
|
+ <groupId>org.apache.maven.plugins</groupId>
|
|
|
+ <artifactId>maven-assembly-plugin</artifactId>
|
|
|
+ <executions>
|
|
|
+ <execution>
|
|
|
+ <id>assemble</id>
|
|
|
+ <phase>package</phase>
|
|
|
+ <goals>
|
|
|
+ <goal>single</goal>
|
|
|
+ </goals>
|
|
|
+ <configuration>
|
|
|
+ <descriptors>
|
|
|
+ <descriptor>assembly.xml</descriptor>
|
|
|
+ </descriptors>
|
|
|
+ <!–<recompressZippedFiles>true</recompressZippedFiles>–>
|
|
|
+ <finalName>shoulder-specs-${project.version}</finalName>
|
|
|
+ <appendAssemblyId>false</appendAssemblyId>
|
|
|
+ <outputDirectory>target/</outputDirectory>
|
|
|
+ <workDirectory>target/assembly/work</workDirectory>
|
|
|
+ <tarLongFileMode>gnu</tarLongFileMode>
|
|
|
+ </configuration>
|
|
|
+ </execution>
|
|
|
+ </executions>
|
|
|
+ </plugin>-->
|
|
|
+ </plugins>
|
|
|
+ </build>
|
|
|
+
|
|
|
+
|
|
|
+</project>
|