-
Notifications
You must be signed in to change notification settings - Fork 10.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Simplify our
maven-javadoc-plugin
configuration, and move both it a…
…nd `maven-source-plugin` to the default phase (which is `package`). I doubt that this ends up being a complete no-op in all scenarios (if only because of the phase change), but I didn't _set out_ intending to change any behavior, and my various tests all passed: - `mvn clean javadoc:jar deploy -DskipTests=true -Dmaven.deploy.skip=true` (also also a similar test _without_ `javadoc:jar`, as discussed below) - `mvn clean deploy -Psonatype-oss-release -DskipTests -Drelease -Dmaven.deploy.skip=true` (now that it's passing after cl/572327204) - `mvn clean install -DskipTests` As part of this CL, I'm removing `javadoc:jar` from the command line we use for snapshots. I do this out of fear that it will someday result in "duplicated artifacts" (like cl/571437790), use the wrong configuration, or just run twice—as apparently it does in my test of the main changes from this CL: ``` [INFO] --- javadoc:3.5.0:jar (default-cli) @ guava --- [INFO] No previous run data found, generating javadoc. [INFO] Building jar: /usr/local/google/home/cpovirk/tmp.lS88PuqjZ4/git/guava/target/guava-HEAD-jre-SNAPSHOT-javadoc.jar ... [INFO] --- javadoc:3.5.0:jar (attach-docs) @ guava --- [INFO] Configuration changed, re-generating javadoc. [INFO] Building jar: /usr/local/google/home/cpovirk/tmp.lS88PuqjZ4/git/guava/target/guava-HEAD-jre-SNAPSHOT-javadoc.jar ``` The new snapshot command appears to run Javadoc exactly once, as desired: ``` [INFO] --- javadoc:3.5.0:jar (attach-docs) @ guava --- [INFO] No previous run data found, generating javadoc. ``` (While in the neighborhood, I considered also investigating a [switch from `jar` to `jar-no-fork`](https://maven.apache.org/plugins/maven-javadoc-plugin/examples/javadoc-nofork.html), similar to what we did for `maven-source-plugin`, but I didn't bother. FWIW, I didn't notice any duplicate steps, so the switch might not buy us anything for Guava in particular.) Also, I removed some mentions of `org.apache.maven.plugins`, which are redundant because that is the default. RELNOTES=n/a PiperOrigin-RevId: 572593797
- Loading branch information
Showing
5 changed files
with
5 additions
and
89 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters