pom.xml 20 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  3. xmlns="http://maven.apache.org/POM/4.0.0"
  4. xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
  5. <modelVersion>4.0.0</modelVersion>
  6. <parent>
  7. <groupId>io.awspring.cloud</groupId>
  8. <artifactId>spring-cloud-aws</artifactId>
  9. <version>3.1.0-SNAPSHOT</version>
  10. </parent>
  11. <artifactId>spring-cloud-aws-docs</artifactId>
  12. <packaging>pom</packaging>
  13. <name>Spring Cloud AWS Docs</name>
  14. <properties>
  15. <docs.main>spring-cloud-aws</docs.main>
  16. <main.basedir>${basedir}/..</main.basedir>
  17. <configprops.inclusionPattern>spring.cloud.aws.*</configprops.inclusionPattern>
  18. <upload-docs-zip.phase>deploy</upload-docs-zip.phase>
  19. <generated-docs-multipage-output.dir>${project.build.directory}/generated-docs/${project.version}/reference/html</generated-docs-multipage-output.dir>
  20. <generated-docs-singlepage-output.dir>${project.build.directory}/generated-docs/${project.version}/reference/htmlsingle</generated-docs-singlepage-output.dir>
  21. <generated-docs-pdf-output.dir>${project.build.directory}/generated-docs/${project.version}/reference/pdf</generated-docs-pdf-output.dir>
  22. </properties>
  23. <build>
  24. <plugins>
  25. <plugin>
  26. <groupId>org.apache.maven.plugins</groupId>
  27. <artifactId>maven-deploy-plugin</artifactId>
  28. <version>${maven-deploy-plugin.version}</version>
  29. <configuration>
  30. <skip>true</skip>
  31. </configuration>
  32. </plugin>
  33. </plugins>
  34. </build>
  35. <dependencies>
  36. <dependency>
  37. <groupId>io.awspring.cloud</groupId>
  38. <artifactId>spring-cloud-aws-autoconfigure</artifactId>
  39. </dependency>
  40. </dependencies>
  41. <profiles>
  42. <profile>
  43. <id>docs-classic</id>
  44. <build>
  45. <pluginManagement>
  46. <plugins>
  47. <plugin>
  48. <groupId>org.apache.maven.plugins</groupId>
  49. <artifactId>maven-dependency-plugin</artifactId>
  50. <version>${maven-dependency-plugin.version}</version>
  51. <executions>
  52. <execution>
  53. <id>unpack-docs</id>
  54. <phase>${maven-dependency-plugin-for-docs.phase}</phase>
  55. <goals>
  56. <goal>unpack</goal>
  57. </goals>
  58. <configuration>
  59. <artifactItems>
  60. <artifactItem>
  61. <groupId>org.springframework.cloud
  62. </groupId>
  63. <artifactId>spring-cloud-build-docs
  64. </artifactId>
  65. <version>${spring-cloud-build.version}
  66. </version>
  67. <classifier>sources</classifier>
  68. <type>jar</type>
  69. <overWrite>true</overWrite>
  70. <outputDirectory>${docs.resources.dir}
  71. </outputDirectory>
  72. </artifactItem>
  73. </artifactItems>
  74. </configuration>
  75. </execution>
  76. <execution>
  77. <id>unpack-classes</id>
  78. <phase>${maven-dependency-plugin-for-docs-classes.phase}</phase>
  79. <goals>
  80. <goal>unpack</goal>
  81. </goals>
  82. <configuration>
  83. <artifactItems>
  84. <artifactItem>
  85. <groupId>org.springframework.cloud
  86. </groupId>
  87. <artifactId>spring-cloud-build-docs
  88. </artifactId>
  89. <version>${spring-cloud-build.version}
  90. </version>
  91. <classifier>jar-with-dependencies</classifier>
  92. <type>jar</type>
  93. <overWrite>true</overWrite>
  94. <outputDirectory>${docs.classes.dir}
  95. </outputDirectory>
  96. </artifactItem>
  97. </artifactItems>
  98. </configuration>
  99. </execution>
  100. </executions>
  101. </plugin>
  102. <plugin>
  103. <groupId>org.apache.maven.plugins</groupId>
  104. <artifactId>maven-resources-plugin</artifactId>
  105. <executions>
  106. <execution>
  107. <id>copy-asciidoc-resources</id>
  108. <phase>generate-resources</phase>
  109. <goals>
  110. <goal>copy-resources</goal>
  111. </goals>
  112. <configuration>
  113. <outputDirectory>${project.build.directory}/refdocs/</outputDirectory>
  114. <resources>
  115. <resource>
  116. <directory>src/main/asciidoc</directory>
  117. <excludes>
  118. <exclude>ghpages.sh</exclude>
  119. </excludes>
  120. </resource>
  121. </resources>
  122. </configuration>
  123. </execution>
  124. </executions>
  125. </plugin>
  126. <plugin>
  127. <groupId>org.codehaus.mojo</groupId>
  128. <artifactId>exec-maven-plugin</artifactId>
  129. <version>${exec-maven-plugin.version}</version>
  130. <executions>
  131. <execution>
  132. <id>generate-configprops</id>
  133. <phase>prepare-package</phase>
  134. <goals>
  135. <goal>java</goal>
  136. </goals>
  137. </execution>
  138. </executions>
  139. <dependencies>
  140. <dependency>
  141. <groupId>org.springframework.cloud
  142. </groupId>
  143. <artifactId>spring-cloud-build-docs
  144. </artifactId>
  145. <version>${spring-cloud-build.version}
  146. </version>
  147. <classifier>${spring-cloud-build-docs-classifier}</classifier>
  148. <type>jar</type>
  149. </dependency>
  150. </dependencies>
  151. <configuration>
  152. <includePluginDependencies>
  153. true
  154. </includePluginDependencies>
  155. <mainClass>org.springframework.cloud.internal.Main</mainClass>
  156. <arguments>
  157. <argument>${configprops.path}</argument>
  158. <argument>${configprops.inclusionPattern}</argument>
  159. </arguments>
  160. </configuration>
  161. </plugin>
  162. <plugin>
  163. <groupId>org.asciidoctor</groupId>
  164. <artifactId>asciidoctor-maven-plugin</artifactId>
  165. <version>${asciidoctor-maven-plugin.version}</version>
  166. <dependencies>
  167. <dependency>
  168. <groupId>io.spring.asciidoctor.backends</groupId>
  169. <artifactId>spring-asciidoctor-backends</artifactId>
  170. <version>${spring-asciidoctor-backends.version}</version>
  171. </dependency>
  172. <dependency>
  173. <groupId>org.asciidoctor</groupId>
  174. <artifactId>asciidoctorj-pdf</artifactId>
  175. <version>${asciidoctorj-pdf.version}</version>
  176. </dependency>
  177. <dependency>
  178. <groupId>org.asciidoctor</groupId>
  179. <artifactId>asciidoctorj-diagram</artifactId>
  180. <version>${asciidoctorj-diagram.version}</version>
  181. </dependency>
  182. </dependencies>
  183. <configuration>
  184. <sourceDirectory>${refdocs.build.directory}</sourceDirectory>
  185. <resources>
  186. <resource>
  187. <directory>${refdocs.build.directory}</directory>
  188. <excludes>
  189. <exclude>**/*.*adoc</exclude>
  190. </excludes>
  191. </resource>
  192. </resources>
  193. <!-- tag::attributes[] -->
  194. <attributes>
  195. <docinfo>shared</docinfo>
  196. <allow-uri-read>true</allow-uri-read>
  197. <nofooter/>
  198. <toc>left</toc>
  199. <toc-levels>4</toc-levels>
  200. <sectlinks>true</sectlinks>
  201. <sources-root>${project.basedir}/src@</sources-root>
  202. <asciidoc-sources-root>${project.basedir}/src/main/asciidoc@</asciidoc-sources-root>
  203. <generated-resources-root>${project.basedir}/target/generated-resources@
  204. </generated-resources-root>
  205. <!-- Use this attribute the reference code from another module -->
  206. <!-- Note the @ at the end, lowering the precedence of the attribute -->
  207. <project-root>${maven.multiModuleProjectDirectory}@</project-root>
  208. <!-- It's mandatory for you to pass the docs.main property -->
  209. <github-repo>${docs.main}@</github-repo>
  210. <github-project>https://github.com/spring-cloud/${docs.main}@</github-project>
  211. <github-raw>
  212. https://raw.githubusercontent.com/spring-cloud/${docs.main}/${github-tag}@
  213. </github-raw>
  214. <github-code>https://github.com/spring-cloud/${docs.main}/tree/${github-tag}@
  215. </github-code>
  216. <github-issues>https://github.com/spring-cloud/${docs.main}/issues/@</github-issues>
  217. <github-wiki>https://github.com/spring-cloud/${docs.main}/wiki@</github-wiki>
  218. <github-master-code>https://github.com/spring-cloud/${docs.main}/tree/master@
  219. </github-master-code>
  220. <index-link>${index-link}@</index-link>
  221. <!-- Spring Cloud specific -->
  222. <!-- for backward compatibility -->
  223. <spring-cloud-version>${project.version}@</spring-cloud-version>
  224. <project-version>${project.version}@</project-version>
  225. <github-tag>${github-tag}@</github-tag>
  226. <version-type>${version-type}@</version-type>
  227. <docs-url>https://docs.spring.io/${docs.main}/docs/${project.version}@</docs-url>
  228. <raw-docs-url>${github-raw}@</raw-docs-url>
  229. <project-version>${project.version}@</project-version>
  230. <project-name>${docs.main}@</project-name>
  231. <source-highlighter>highlight.js</source-highlighter>
  232. </attributes>
  233. <!-- end::attributes[] -->
  234. <requires>
  235. <require>asciidoctor-diagram</require>
  236. </requires>
  237. </configuration>
  238. <executions>
  239. <execution>
  240. <id>generate-html-documentation</id>
  241. <phase>${generate-docs.phase}</phase>
  242. <goals>
  243. <goal>process-asciidoc</goal>
  244. </goals>
  245. <configuration>
  246. <backend>spring-html</backend>
  247. <sourceDocumentExtensions>
  248. <sourceDocumentExtension>.adoc</sourceDocumentExtension>
  249. <sourceDocumentExtension>.htmladoc</sourceDocumentExtension>
  250. </sourceDocumentExtensions>
  251. <outputDirectory>${generated-docs-multipage-output.dir}
  252. </outputDirectory>
  253. <doctype>book</doctype>
  254. <attributes>
  255. <docinfo>shared</docinfo>
  256. <stylesdir>css/</stylesdir>
  257. <stylesheet>site.css</stylesheet>
  258. <linkcss>true</linkcss>
  259. <icons>font</icons>
  260. <highlightjsdir>js/highlight</highlightjsdir>
  261. <highlightjs-theme>github</highlightjs-theme>
  262. <imagesdir>./images</imagesdir>
  263. <attribute-missing>warn</attribute-missing>
  264. <source-highlighter>highlight.js</source-highlighter>
  265. </attributes>
  266. <logHandler>
  267. <outputToConsole>true</outputToConsole>
  268. <failIf>
  269. <!-- <severity>DEBUG</severity>-->
  270. </failIf>
  271. </logHandler>
  272. </configuration>
  273. </execution>
  274. <execution>
  275. <id>generate-htmlsingle-documentation</id>
  276. <phase>${generate-docs.phase}</phase>
  277. <goals>
  278. <goal>process-asciidoc</goal>
  279. </goals>
  280. <configuration>
  281. <backend>spring-html</backend>
  282. <sourceDocumentExtensions>
  283. <sourceDocumentExtension>.htmlsingleadoc</sourceDocumentExtension>
  284. </sourceDocumentExtensions>
  285. <outputDirectory>
  286. ${generated-docs-singlepage-output.dir}
  287. </outputDirectory>
  288. <doctype>book</doctype>
  289. <attributes>
  290. <source-highlighter>highlight.js</source-highlighter>
  291. <docinfo>shared</docinfo>
  292. <stylesdir>css/</stylesdir>
  293. <stylesheet>site.css</stylesheet>
  294. <linkcss>true</linkcss>
  295. <icons>font</icons>
  296. <highlightjsdir>js/highlight</highlightjsdir>
  297. <highlightjs-theme>github</highlightjs-theme>
  298. <imagesdir>./images</imagesdir>
  299. </attributes>
  300. </configuration>
  301. </execution>
  302. <execution>
  303. <id>generate-pdf-documentation</id>
  304. <phase>${generate-docs.phase}</phase>
  305. <goals>
  306. <goal>process-asciidoc</goal>
  307. </goals>
  308. <configuration>
  309. <backend>pdf</backend>
  310. <sourceDocumentExtensions>
  311. <sourceDocumentExtension>.pdfadoc</sourceDocumentExtension>
  312. </sourceDocumentExtensions>
  313. <outputDirectory>${generated-docs-pdf-output.dir}
  314. </outputDirectory>
  315. <resources>
  316. <resource>
  317. <directory>${refdocs.build.directory}</directory>
  318. <excludes>
  319. <exclude>**/*</exclude>
  320. </excludes>
  321. </resource>
  322. </resources>
  323. </configuration>
  324. </execution>
  325. </executions>
  326. </plugin>
  327. <plugin>
  328. <groupId>org.apache.maven.plugins</groupId>
  329. <artifactId>maven-antrun-plugin</artifactId>
  330. <version>${maven-antrun-plugin.version}</version>
  331. <dependencies>
  332. <dependency>
  333. <groupId>ant-contrib</groupId>
  334. <artifactId>ant-contrib</artifactId>
  335. <version>1.0b3</version>
  336. <exclusions>
  337. <exclusion>
  338. <groupId>ant</groupId>
  339. <artifactId>ant</artifactId>
  340. </exclusion>
  341. </exclusions>
  342. </dependency>
  343. <dependency>
  344. <groupId>org.apache.ant</groupId>
  345. <artifactId>ant-nodeps</artifactId>
  346. <version>${ant-nodeps.version}</version>
  347. </dependency>
  348. <dependency>
  349. <groupId>org.tigris.antelope</groupId>
  350. <artifactId>antelopetasks</artifactId>
  351. <version>${antelopetasks.version}</version>
  352. </dependency>
  353. <dependency>
  354. <groupId>org.jruby</groupId>
  355. <artifactId>jruby-complete</artifactId>
  356. <version>${jruby-complete.version}</version>
  357. </dependency>
  358. <dependency>
  359. <groupId>org.asciidoctor</groupId>
  360. <artifactId>asciidoctorj</artifactId>
  361. <version>${asciidoctorj.version}</version>
  362. </dependency>
  363. </dependencies>
  364. <executions>
  365. <execution>
  366. <id>readme</id>
  367. <phase>prepare-package</phase>
  368. <goals>
  369. <goal>run</goal>
  370. </goals>
  371. <configuration>
  372. <target>
  373. <path id="readme.class.path">
  374. <pathelement location="${readme.main.classpath}"/>
  375. </path>
  376. <java classname="org.springframework.cloud.internal.asciidoctor.ReadmeMain"
  377. failonerror="yes" classpathref="${readme.class.path}">
  378. <!-- Input -->
  379. <arg value="${project.basedir}/src/main/asciidoc/README.adoc"/>
  380. <!-- Output -->
  381. <arg value="${main.basedir}/README.adoc"/>
  382. </java>
  383. </target>
  384. </configuration>
  385. </execution>
  386. <execution>
  387. <id>assert-no-unresolved-links</id>
  388. <phase>${generate-docs.phase}</phase>
  389. <goals>
  390. <goal>run</goal>
  391. </goals>
  392. <configuration>
  393. <target>
  394. <fileset id="unresolved.file" dir="${basedir}/target/generated-docs/"
  395. includes="**/*.html">
  396. <contains text="Unresolved"/>
  397. </fileset>
  398. <fail message="[Unresolved] Found...failing">
  399. <condition>
  400. <resourcecount when="greater"
  401. count="0"
  402. refid="unresolved.file"/>
  403. </condition>
  404. </fail>
  405. </target>
  406. </configuration>
  407. </execution>
  408. <execution>
  409. <id>copy-missing-html-files</id>
  410. <phase>${copy-missing-html-files.phase}</phase>
  411. <goals>
  412. <goal>run</goal>
  413. </goals>
  414. <configuration>
  415. <failOnError>false</failOnError>
  416. <target>
  417. <copy tofile="${project.build.directory}/generated-docs/reference/htmlsingle/index.html">
  418. <fileset dir="${project.build.directory}/generated-docs/reference/htmlsingle" includes="${docs.main}.html" />
  419. </copy>
  420. </target>
  421. </configuration>
  422. </execution>
  423. <execution>
  424. <id>package-and-attach-docs-zip</id>
  425. <phase>${package-and-attach-docs-zip.phase}</phase>
  426. <goals>
  427. <goal>run</goal>
  428. </goals>
  429. <configuration>
  430. <target>
  431. <zip
  432. destfile="${project.build.directory}/${project.artifactId}-${revision}.zip">
  433. <!--<zipfileset
  434. src="${project.build.directory}/${project.artifactId}-${revision}-javadoc.jar"
  435. prefix="api" />-->
  436. <!-- <fileset dir="${project.build.directory}/contents"/>-->
  437. <fileset dir="${project.build.directory}/generated-docs"/>
  438. </zip>
  439. </target>
  440. </configuration>
  441. </execution>
  442. <execution>
  443. <id>setup-maven-properties</id>
  444. <phase>initialize</phase>
  445. <goals>
  446. <goal>run</goal>
  447. </goals>
  448. <configuration>
  449. <exportAntProperties>true</exportAntProperties>
  450. <target>
  451. <taskdef resource="net/sf/antcontrib/antcontrib.properties"/>
  452. <taskdef name="stringutil" classname="ise.antelope.tasks.StringUtilTask"/>
  453. <var name="version-type" value="${revision}"/>
  454. <propertyregex property="version-type" override="true"
  455. input="${version-type}" regexp=".*\.(.*)" replace="\1"/>
  456. <propertyregex property="version-type" override="true"
  457. input="${version-type}" regexp="(M)\d+" replace="MILESTONE"/>
  458. <propertyregex property="version-type" override="true"
  459. input="${version-type}" regexp="(RC)\d+"
  460. replace="MILESTONE"/>
  461. <propertyregex property="version-type" override="true"
  462. input="${version-type}" regexp="BUILD-(.*)"
  463. replace="SNAPSHOT"/>
  464. <stringutil string="${version-type}" property="spring-cloud-repo">
  465. <lowercase/>
  466. </stringutil>
  467. <propertyregex property="git.branch" override="true"
  468. input="${git.branch}" regexp="origin/(.*)"
  469. replace="\1"/>
  470. <var name="github-tag" value="${git.branch}"/>
  471. </target>
  472. </configuration>
  473. </execution>
  474. </executions>
  475. </plugin>
  476. <plugin>
  477. <groupId>org.jfrog.buildinfo</groupId>
  478. <artifactId>artifactory-maven-plugin</artifactId>
  479. <version>${artifactory-maven-plugin.version}</version>
  480. <executions>
  481. <execution>
  482. <id>build-info</id>
  483. <goals>
  484. <goal>publish</goal>
  485. </goals>
  486. <configuration>
  487. <deployProperties>
  488. <zip.deployed>true</zip.deployed>
  489. <zip.type>docs</zip.type>
  490. </deployProperties>
  491. <publisher>
  492. <contextUrl>https://repo.spring.io
  493. </contextUrl>
  494. <repoKey>libs-release-local</repoKey>
  495. <snapshotRepoKey>libs-snapshots-local
  496. </snapshotRepoKey>
  497. </publisher>
  498. </configuration>
  499. </execution>
  500. </executions>
  501. </plugin>
  502. <plugin>
  503. <artifactId>maven-deploy-plugin</artifactId>
  504. <version>${maven-deploy-plugin.version}</version>
  505. <executions>
  506. <execution>
  507. <id>default-deploy</id>
  508. <phase>${maven-deploy-plugin-default.phase}</phase>
  509. <goals>
  510. <goal>deploy</goal>
  511. </goals>
  512. </execution>
  513. <execution>
  514. <id>upload-docs-zip</id>
  515. <phase>${upload-docs-zip.phase}</phase>
  516. <goals>
  517. <goal>deploy-file</goal>
  518. </goals>
  519. <configuration>
  520. <generatePom>false</generatePom>
  521. <groupId>${project.groupId}</groupId>
  522. <artifactId>${project.artifactId}</artifactId>
  523. <version>${project.version}</version>
  524. <repositoryId>${maven-deploy-plugin.deployZipRepositoryId}</repositoryId>
  525. <url>${maven-deploy-plugin.deployZipUrl}</url>
  526. <file>${project.build.directory}/${project.artifactId}-${project.version}.zip</file>
  527. <packaging>zip;zip.type=docs;zip.deployed=false;</packaging>
  528. </configuration>
  529. </execution>
  530. </executions>
  531. </plugin>
  532. </plugins>
  533. </pluginManagement>
  534. <plugins>
  535. <plugin>
  536. <groupId>pl.project13.maven</groupId>
  537. <artifactId>git-commit-id-plugin</artifactId>
  538. </plugin>
  539. <plugin>
  540. <groupId>org.codehaus.mojo</groupId>
  541. <artifactId>exec-maven-plugin</artifactId>
  542. </plugin>
  543. <plugin>
  544. <groupId>org.apache.maven.plugins</groupId>
  545. <artifactId>maven-dependency-plugin</artifactId>
  546. </plugin>
  547. <plugin>
  548. <groupId>org.apache.maven.plugins</groupId>
  549. <artifactId>maven-resources-plugin</artifactId>
  550. </plugin>
  551. <plugin>
  552. <groupId>org.asciidoctor</groupId>
  553. <artifactId>asciidoctor-maven-plugin</artifactId>
  554. <configuration>
  555. <attributes>
  556. <source-highlighter>highlight.js</source-highlighter>
  557. </attributes>
  558. </configuration>
  559. </plugin>
  560. <plugin>
  561. <groupId>org.apache.maven.plugins</groupId>
  562. <artifactId>maven-antrun-plugin</artifactId>
  563. </plugin>
  564. </plugins>
  565. </build>
  566. </profile>
  567. </profiles>
  568. </project>