On Wed, 19 Aug 2026 17:06:15 GMT, Jaikiran Pai <[email protected]> wrote:

>> Can I please get a review of this doc-only change which updates the text in 
>> the `jar --help` output as well as the `jar` man page to clarify the usage 
>> of the `-C` option? 
>> 
>> As noted in https://bugs.openjdk.org/browse/JDK-8390615, the current 
>> examples in the `jar --help` can cause confusion on the expectations of the 
>> `-C` option. The updated text in the man page will also address a related 
>> issue noted in https://bugs.openjdk.org/browse/JDK-8389482.
>> 
>> While at it, trivial adjustment to the text in `jar --help` and `jar` man 
>> page has been done to use "JAR" (instead of "jar") whenever referencing to a 
>> JAR file.
>> 
>> I've run manual experiments to verify that these commands now work as 
>> described.
>> 
>> ---------
>> - [x] I confirm that I make this contribution in accordance with the 
>> [OpenJDK Interim AI Policy](https://openjdk.org/legal/ai).
>
> Jaikiran Pai has updated the pull request incrementally with one additional 
> commit since the last revision:
> 
>   additional adjustments

src/jdk.jartool/share/man/jar.md line 36:

> 34: ## Synopsis
> 35: 
> 36: `jar` \[*OPTION* ...\] \[ \[`--release` *VERSION*\] \[`-C` *dir*\] 
> *files*\]

This has "files" so now I think the man page has a mix of "file" and "files".

src/jdk.jartool/share/man/jar.md line 126:

> 124: 
> 125:     When used in create mode, if the file is a directory then it is
> 126:     processed recursively.

Is it recursive in update mode?

src/jdk.jartool/share/man/jar.md line 265:

> 263: 
> 264:     >   `jar --create --file foo.jar --main-class com.foo.Main
> 265:         --module-version 1.0 -C foo/classes module-info.class`

I assume "resources" means all resources in the module, including the main 
class and module-info.class. If someone copies the example then they may be 
disappointed that it will fail so I think we need to least have it include 
com/foo/Main.class to match the --main-class option.

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/32439#discussion_r3815342720
PR Review Comment: https://git.openjdk.org/jdk/pull/32439#discussion_r3815354605
PR Review Comment: https://git.openjdk.org/jdk/pull/32439#discussion_r3815325429

Reply via email to