[
https://jira.codehaus.org/browse/MJAVADOC-299?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Michael Osipov closed MJAVADOC-299.
-----------------------------------
Resolution: Won't Fix
Please refer to
https://cwiki.apache.org/confluence/display/MAVEN/The+Great+JIRA+Cleanup+of+2014
if you're wondering why this issue was closed out.
> excludePackageNames has no effect if subpackages is specified
> -------------------------------------------------------------
>
> Key: MJAVADOC-299
> URL: https://jira.codehaus.org/browse/MJAVADOC-299
> Project: Maven Javadoc Plugin
> Issue Type: Bug
> Affects Versions: 2.7
> Reporter: Paul Mealor
> Priority: Minor
> Attachments: MJAVADOC-299_IT_Test.patch, MJAVADOC-299.zip
>
>
> I am using a configuration something like the following:
> {code:xml} <build>
> <plugins>
> <plugin>
> <groupId>org.apache.maven.plugins</groupId>
> <artifactId>maven-javadoc-plugin</artifactId>
> <version>2.7</version>
> <executions>
> <execution>
> <configuration>
> <subpackages>foo.bar.api</subpackages>
>
> <excludePackageNames>foo.bar.api.impl:*impl:*.impl</excludePackageNames>
> <debug>true</debug>
> </configuration>
> <goals>
> <goal>jar</goal>
> </goals>
> </execution>
> </executions>
> </plugin>
> </plugins>
> </build>{code}
> When I do this, every package under subpackages is included in my Javadoc,
> including foo.bar.api.impl. The @options file includes "-subpackages
> foo.bar.api", but does not include "-exclude". No @packages file is created.
> If I do not include <subpackages/>, the <excludePackageNames/> works as
> desired: an @packages file is produced that excludes every package named like
> *.impl. Unfortunately, in my case, this means that packages like foo.bar.qux
> is included in the Javadoc, and I do not want that included.
> It would seem sensible if <subpackages/> was used to generate the @packages
> file, the same as if no packages are specified. Then <excludePackageNames/>
> could be applied to the list of packages in that file.
> My best workaround so far is to do the following, which tricks Javadoc and
> the plugin into building only foo.bar.api and foo.bar.api.event
> {code:xml} <build>
> <plugins>
> <plugin>
> <groupId>org.apache.maven.plugins</groupId>
> <artifactId>maven-javadoc-plugin</artifactId>
> <version>2.7</version>
> <executions>
> <execution>
> <configuration>
> <subpackages>none</subpackages>
> <additionalparam>foo.bar.api foo.bar.api.event</additionalparam>
> <debug>true</debug>
> </configuration>
> <goals>
> <goal>jar</goal>
> </goals>
> </execution>
> </executions>
> </plugin>
> </plugins>
> </build>{code}
--
This message was sent by Atlassian JIRA
(v6.1.6#6162)