Hello. I have a module in most of my projects that generates documentation written in a custom documentation language, and then packs that documentation into a standalone archive along with the aggregated javadocs of the project (deployed along with the rest of the Maven artifacts to Central, etc). I then unpack that documentation into the staged site so that the most recent version essentially appears as part of the site. As a practical example, this is a generated site:
http://io7m.github.io/jstructural/ The 'Documentation' link leads to: http://io7m.github.io/jstructural/releases.html#Documentation ... and the "one page per section" link leads to the documentation that was unpacked as part of the build: http://io7m.github.io/jstructural/documentation/index-m.xhtml This is achieved via the following unpleasantness: https://github.com/io7m/jstructural/blob/master/io7m-jstructural-documentation/pom.xml Yes, I'm aware that there are multiple things to hate about this POM, but I'm attempting to address these one at a time. The main problem I'm trying to fix now: The module aggregates javadocs from the other modules. If the build is executed with -Dmaven.javadoc.skip=true the whole build fails because the javadoc artifacts haven't been created in the dependencies and are therefore considered missing by the documentation module. The only sane solution I can think of is to activate a profile that enables the javadoc dependencies when javadoc generation is not being skipped. This would seem to require checking: !maven.javadoc.skip || maven.javadoc.skip == false Unfortunately, profiles can't be activated with multiple property conditions. Is there a reasonable way to handle so that the project: a) Gives the standard behaviour (all documentation and javadoc generated) when mvn is executed with no special arguments. b) Produces a build that just does not contain any javadoc when -Dmaven.javadoc.skip=true, but still builds correctly and otherwise produces documentation. c) "just works" with a default Maven install (there's an extension out there for activating profiles based on an expression language, but it requires users to modify their local installation). M --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org