Skip to content

Commit

Permalink
docs: Latest for Cloud-RAD (#199)
Browse files Browse the repository at this point in the history
* Latest for Cloud-RAD

* Initial try at DocFX (still in progress)
* send correct paths to Javadoc / docLava
* Simplify AntRun processing

* chore(docs): Fix code review problems

* Make sure google-java-format version is 1.7
* Add comment to use of SNAPSHOT
  • Loading branch information
lesv committed Oct 20, 2020
1 parent 0cf9c25 commit 34712af
Showing 1 changed file with 71 additions and 19 deletions.
90 changes: 71 additions & 19 deletions pom.xml
@@ -1,5 +1,7 @@
<?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">
<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>com.google.cloud</groupId>
<artifactId>google-cloud-shared-config</artifactId>
Expand All @@ -26,7 +28,8 @@
</organization>
<scm>
<connection>scm:git:git@github.com:googleapis/java-shared-config.git</connection>
<developerConnection>scm:git:git@github.com:googleapis/java-shared-config.git</developerConnection>
<developerConnection>scm:git:git@github.com:googleapis/java-shared-config.git
</developerConnection>
<url>https://github.com/googleapis/java-shared-config</url>
<tag>HEAD</tag>
</scm>
Expand Down Expand Up @@ -195,7 +198,8 @@
<version>3.1.2</version>
<configuration>
<ignoredUnusedDeclaredDependencies>
<ignoredUnusedDeclaredDependency>javax.annotation:javax.annotation-api</ignoredUnusedDeclaredDependency>
<ignoredUnusedDeclaredDependency>javax.annotation:javax.annotation-api
</ignoredUnusedDeclaredDependency>
</ignoredUnusedDeclaredDependencies>
</configuration>
</plugin>
Expand Down Expand Up @@ -640,12 +644,59 @@
</plugins>
</build>
</profile>

<profile>
<id>enable-integration-tests</id>
<properties>
<skipITs>false</skipITs>
</properties>
</profile>

<profile>
<!-- NOTE - this profile is still in progress and needs work -->
<id>docFX</id>
<activation>
<property>
<name>docFX</name>
</property>
</activation>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<version>3.2.0</version>
<executions>
<execution>
<phase>site</phase>
<goals>
<goal>aggregate</goal>
</goals>
</execution>
</executions>
<configuration>
<doclet>com.microsoft.doclet.DocFxDoclet</doclet>
<docletArtifact>
<groupId>com.microsoft</groupId>
<artifactId>docfx-doclet</artifactId>
<version>1.0-SNAPSHOT</version><!-- this is temporary - NO PRODUCTION USE -->
</docletArtifact>
<additionalDependencies>
<additionalDependency>
<groupId>com.google.j2objc</groupId>
<artifactId>j2objc-annotations</artifactId>
<version>1.3</version>
</additionalDependency>
</additionalDependencies>
<useStandardDocletOptions>false</useStandardDocletOptions>
<additionalOptions>-outputpath ${project.build.directory}/docfx/</additionalOptions>
<!-- Add additional options here when needed -->
</configuration>
</plugin>
</plugins>
</build>
</profile>

<profile>
<id>devsite-apidocs</id>
<activation>
Expand All @@ -656,6 +707,8 @@
</activation>
<build>
<plugins>
<!-- WARNING - JavaDoc / DocLava must be run using Java 8 and nothing higher
AntRun version must be the correct version or the syntax below is incorrect! -->
<plugin>
<!-- Generate API docs using Doclava for the developer site. -->
<artifactId>maven-javadoc-plugin</artifactId>
Expand Down Expand Up @@ -693,13 +746,13 @@
<additionalOption>/java/_project.yaml</additionalOption>
<additionalOption>-hdf</additionalOption>
<additionalOption>devsite.path</additionalOption>
<additionalOption>${docRoot}</additionalOption>
<additionalOption>${docRoot}${env.NAME}/latest/</additionalOption>
<additionalOption>-d</additionalOption>
<additionalOption>${project.build.directory}/devsite</additionalOption>
<additionalOption>-templatedir</additionalOption>
<additionalOption>${devsite.template}</additionalOption>
<additionalOption>-toroot</additionalOption>
<additionalOption>${docRoot}</additionalOption>
<additionalOption>${docRoot}${env.NAME}/latest/</additionalOption>
<additionalOption>-yaml</additionalOption>
<additionalOption>_toc.yaml</additionalOption>
<additionalOption>-warning</additionalOption>
Expand All @@ -711,7 +764,7 @@
<plugin>
<!-- Clean up some references and files. -->
<artifactId>maven-antrun-plugin</artifactId>
<version>1.8</version>
<version>3.0.0</version>
<executions>
<execution>
<phase>site</phase>
Expand All @@ -720,19 +773,18 @@
</goals>
<configuration>
<target>
<echo message="Updating relative links in API docs" />
<!-- TODO: What is the right behavior for io* and google*? -->
<replace dir="${project.build.directory}/devsite" token="href=&quot;com" value="href=&quot;${docRoot}com" />
<replace dir="${project.build.directory}/devsite" token="href=&quot;io" value="href=&quot;${docRoot}io" />
<replace dir="${project.build.directory}/devsite" token="href=&quot;google" value="href=&quot;${docRoot}google" />
<copy file="${project.build.directory}/devsite/assets/_toc.yaml" todir="${project.build.directory}/devsite/reference" />
<echo message="Removing files not needed by Devsite" />
<delete file="${project.build.directory}/devsite/reference/classes.html" />
<delete file="${project.build.directory}/devsite/reference/hierarchy.html" />
<delete file="${project.build.directory}/devsite/reference/index.html" />
<delete file="${project.build.directory}/devsite/reference/lists.js" />
<delete file="${project.build.directory}/devsite/reference/packages.html" />
<delete file="${project.build.directory}/devsite/reference/current.xml" />
<echo message="Removing files not needed by CloudSite / DevSite"/>
<delete file="${project.build.directory}/devsite/reference/classes.html"/>
<delete file="${project.build.directory}/devsite/reference/index.html"/>
<delete file="${project.build.directory}/devsite/reference/packages.html"/>
<delete file="${project.build.directory}/devsite/reference/hierarchy.html"/>
<delete file="${project.build.directory}/devsite/reference/lists.js"/>
<delete file="${project.build.directory}/devsite/reference/current.xml"/>

<echo message="duplicating _toc.yaml" />
<copy
file="${project.build.directory}/devsite/assets/_toc.yaml"
todir="${project.build.directory}/devsite/reference" />
</target>
</configuration>
</execution>
Expand Down

0 comments on commit 34712af

Please sign in to comment.