| 
122 | 122 | 		<xmlunit.version>1.5</xmlunit.version>  | 
123 | 123 | 		<xws-security.version>3.0</xws-security.version>  | 
124 | 124 | 		<xom.version>1.2.5</xom.version>  | 
 | 125 | +		<docs.resources.version>0.1.3.RELEASE</docs.resources.version>  | 
125 | 126 | 	</properties>  | 
126 | 127 | 
 
  | 
127 | 128 | 	<dependencyManagement>  | 
 | 
187 | 188 | 			<version>${woodstox.version}</version>  | 
188 | 189 | 			<scope>test</scope>  | 
189 | 190 | 		</dependency>  | 
190 |  | - | 
 | 191 | +		<dependency>  | 
 | 192 | +			<groupId>io.spring.docresources</groupId>  | 
 | 193 | +			<artifactId>spring-doc-resources</artifactId>  | 
 | 194 | +			<version>${docs.resources.version}</version>  | 
 | 195 | +			<type>zip</type>  | 
 | 196 | +			<optional>true</optional>  | 
 | 197 | +		</dependency>  | 
191 | 198 | 	</dependencies>  | 
192 | 199 | 
 
  | 
193 | 200 | 	<build>  | 
 | 
520 | 527 | 			<id>docs</id>  | 
521 | 528 | 
 
  | 
522 | 529 | 			<build>  | 
 | 530 | + | 
523 | 531 | 				<plugins>  | 
 | 532 | +					<plugin>  | 
 | 533 | +						<groupId>org.apache.maven.plugins</groupId>  | 
 | 534 | +						<artifactId>maven-dependency-plugin</artifactId>  | 
 | 535 | +						<executions>  | 
 | 536 | +							<execution>  | 
 | 537 | +								<id>unpack-doc-resources</id>  | 
 | 538 | +								<goals>  | 
 | 539 | +									<goal>unpack-dependencies</goal>  | 
 | 540 | +								</goals>  | 
 | 541 | +								<phase>generate-resources</phase>  | 
 | 542 | +								<inherited>false</inherited>  | 
 | 543 | +								<configuration>  | 
 | 544 | +									<includeGroupIds>io.spring.docresources</includeGroupIds>  | 
 | 545 | +									<includeArtifactIds>spring-doc-resources</includeArtifactIds>  | 
 | 546 | +									<includeTypes>zip</includeTypes>  | 
 | 547 | +									<excludeTransitive>true</excludeTransitive>  | 
 | 548 | +									<outputDirectory>${project.build.directory}/refdocs/</outputDirectory>  | 
 | 549 | +								</configuration>  | 
 | 550 | +							</execution>  | 
 | 551 | +						</executions>  | 
 | 552 | +					</plugin>  | 
 | 553 | +					<plugin>  | 
 | 554 | +						<groupId>org.apache.maven.plugins</groupId>  | 
 | 555 | +						<artifactId>maven-resources-plugin</artifactId>  | 
 | 556 | +						<executions>  | 
 | 557 | +							<execution>  | 
 | 558 | +								<id>copy-asciidoc-resources</id>  | 
 | 559 | +								<phase>generate-resources</phase>  | 
 | 560 | +								<inherited>false</inherited>  | 
 | 561 | +								<goals>  | 
 | 562 | +									<goal>copy-resources</goal>  | 
 | 563 | +								</goals>  | 
 | 564 | +								<configuration>  | 
 | 565 | +									<outputDirectory>${project.build.directory}/refdocs/</outputDirectory>  | 
 | 566 | +									<resources>  | 
 | 567 | +										<resource>  | 
 | 568 | +											<directory>src/main/asciidoctor</directory>  | 
 | 569 | +											<filtering>false</filtering>  | 
 | 570 | +										</resource>  | 
 | 571 | +									</resources>  | 
 | 572 | +								</configuration>  | 
 | 573 | +							</execution>  | 
 | 574 | +						</executions>  | 
 | 575 | +					</plugin>  | 
524 | 576 | 					<plugin>  | 
525 | 577 | 						<groupId>org.asciidoctor</groupId>  | 
526 | 578 | 						<artifactId>asciidoctor-maven-plugin</artifactId>  | 
 | 
536 | 588 | 							<execution>  | 
537 | 589 | 								<id>html</id>  | 
538 | 590 | 								<phase>generate-resources</phase>  | 
 | 591 | +								<inherited>false</inherited>  | 
539 | 592 | 								<goals>  | 
540 | 593 | 									<goal>process-asciidoc</goal>  | 
541 | 594 | 								</goals>  | 
542 | 595 | 								<configuration>  | 
543 | 596 | 									<backend>html5</backend>  | 
544 | 597 | 									<outputDirectory>${project.build.directory}/site/reference/html</outputDirectory>  | 
545 |  | -									<sourceHighlighter>prettify</sourceHighlighter>  | 
 | 598 | +									<sourceHighlighter>highlight.js</sourceHighlighter>  | 
546 | 599 | 									<attributes>  | 
 | 600 | +										// these attributes are required to use the doc resources  | 
 | 601 | +										<docinfo>shared</docinfo>  | 
 | 602 | +										<stylesdir>css/</stylesdir>  | 
 | 603 | +										<stylesheet>spring.css</stylesheet>  | 
 | 604 | +										<linkcss>true</linkcss>  | 
547 | 605 | 										<icons>font</icons>  | 
 | 606 | +										<highlightjsdir>js/highlight</highlightjsdir>  | 
 | 607 | +										<highlightjs-theme>github</highlightjs-theme>  | 
548 | 608 | 										<sectanchors>true</sectanchors>  | 
549 | 609 | 									</attributes>  | 
550 | 610 | 								</configuration>  | 
 | 
553 | 613 | 							<execution>  | 
554 | 614 | 								<id>pdf</id>  | 
555 | 615 | 								<phase>generate-resources</phase>  | 
 | 616 | +								<inherited>false</inherited>  | 
556 | 617 | 								<goals>  | 
557 | 618 | 									<goal>process-asciidoc</goal>  | 
558 | 619 | 								</goals>  | 
 | 
564 | 625 | 						</executions>  | 
565 | 626 | 
 
  | 
566 | 627 | 						<configuration>  | 
567 |  | -							<sourceDirectory>src/main/asciidoctor</sourceDirectory>  | 
 | 628 | +							<sourceDirectory>${project.build.directory}/refdocs/</sourceDirectory>  | 
568 | 629 | 							<sourceDocumentName>index.adoc</sourceDocumentName>  | 
569 | 630 | 							<doctype>book</doctype>  | 
570 | 631 | 							<attributes>  | 
571 | 632 | 								<version>${project.version}</version>  | 
572 | 633 | 								<projectName>${project.name}</projectName>  | 
573 | 634 | 								<projectVersion>${project.version}</projectVersion>  | 
574 | 635 | 								<allow-uri-read>true</allow-uri-read>  | 
575 |  | -								<toclevels>3</toclevels>  | 
 | 636 | +								<toclevels>4</toclevels>  | 
576 | 637 | 								<numbered>true</numbered>  | 
577 | 638 | 								<baseDir>${project.basedir}</baseDir>  | 
578 | 639 | 							</attributes>  | 
 | 
788 | 849 | 				<enabled>false</enabled>  | 
789 | 850 | 			</snapshots>  | 
790 | 851 | 		</repository>  | 
 | 852 | +		<repository>  | 
 | 853 | +			<id>spring-release</id>  | 
 | 854 | +			<name>Spring Releases</name>  | 
 | 855 | +			<url>https://repo.spring.io/release</url>  | 
 | 856 | +			<snapshots>  | 
 | 857 | +				<enabled>false</enabled>  | 
 | 858 | +			</snapshots>  | 
 | 859 | +		</repository>  | 
791 | 860 | 	</repositories>  | 
792 | 861 | 
 
  | 
793 | 862 | 	<pluginRepositories>  | 
 | 
0 commit comments