How do I skip site-generation for modules?

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

How do I skip site-generation for modules?

Russell Gold-3
I want to generate a site for my multi-module project only from the top-level. How do I tell maven to skip running the site plugin on each module?
---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: How do I skip site-generation for modules?

Russell Gold-3
And at the same time, I would like to copy to the site directory some files that were generated during the build (and are now in one of the module jars).

> On Nov 8, 2018, at 1:31 PM, Russell Gold <[hidden email]> wrote:
>
> I want to generate a site for my multi-module project only from the top-level. How do I tell maven to skip running the site plugin on each module?


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: How do I skip site-generation for modules?

jieryn
configure m-site-p:site:skip via property, then in parent set to
false, and children set to true

https://maven.apache.org/plugins/maven-site-plugin/site-mojo.html#skip

or create a separate module called docs or site or something, and only
produce the site in that module
On Thu, Nov 8, 2018 at 2:18 PM Russell Gold <[hidden email]> wrote:

>
> And at the same time, I would like to copy to the site directory some files that were generated during the build (and are now in one of the module jars).
>
> > On Nov 8, 2018, at 1:31 PM, Russell Gold <[hidden email]> wrote:
> >
> > I want to generate a site for my multi-module project only from the top-level. How do I tell maven to skip running the site plugin on each module?
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: How do I skip site-generation for modules?

Manfred Moser-4
In reply to this post by Russell Gold-3
You can use the skip parameter in the individual modules..

https://maven.apache.org/plugins/maven-site-plugin/site-mojo.html#skip

That said ... I think since you want some resources from the you are better off NOT skipping but instead just making it work for the multi module setup.

You just need to fix up naming of folder and artifact id and a few paths. Its definitely possible to do this..

Manfred

Russell Gold wrote on 2018-11-08 11:11:

> And at the same time, I would like to copy to the site directory some files
> that were generated during the build (and are now in one of the module jars).
>
>> On Nov 8, 2018, at 1:31 PM, Russell Gold <[hidden email]> wrote:
>>
>> I want to generate a site for my multi-module project only from the top-level.
>> How do I tell maven to skip running the site plugin on each module?
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: How do I skip site-generation for modules?

Hervé BOUTEMY
In reply to this post by Russell Gold-3
for that, you can copy content to the generatedSiteDirectory [1]:
either $generatedSiteDirectory/resources if you already have html content, or $generatedSiteDirectory/markdown if the generated content is in Markdown, and so on

another option that I sometimes use is to include generated content with a snippet macro: see [2] for example.
The ${project.basedir}/target/test-classes/options.html content was generated by a Unit test.

HTH

Regards,

Hervé

[1] https://maven.apache.org/plugins/maven-site-plugin/site-mojo.html#generatedSiteDirectory

[2] https://github.com/apache/maven/blob/master/maven-embedder/src/site/apt/cli.apt.vm

Le jeudi 8 novembre 2018, 20:11:19 CET Russell Gold a écrit :

> And at the same time, I would like to copy to the site directory some files
> that were generated during the build (and are now in one of the module
> jars).
> > On Nov 8, 2018, at 1:31 PM, Russell Gold <[hidden email]> wrote:
> >
> > I want to generate a site for my multi-module project only from the
> > top-level. How do I tell maven to skip running the site plugin on each
> > module?
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]





---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]