Re: Is it possible to have jacoco's and pmd's report-aggregate in the same Maven artifact?

[email protected]
Newsgroups gmane.comp.jakarta.turbine.maven.user
Message-ID <[email protected]>
Thank you for creating this (and thanks, Tamás, too, for the 
suggestion)!

This seems to be what I need, I'll investigate this option - thanks a 
lot!

Am 06.05.2025 23:02 schrieb Olivier Lamy:
> If it can help, I created a simple mojo to easily aggregate jacoco
> reports for multi modules projects without the need to have extra
> empty module (see
> https://github.com/olamy/jacoco-aggregator-maven-plugin/)
> 
> On Wed, 7 May 2025 at 05:50, <[email protected]> wrote:
>> 
>> Maybe this might be helpful for someone having the same problem: While 
>> I
>> couldn't make it work with the aggregator being the parent as well, as 
>> a
>> workaround I managed to create both aggregating reports in the
>> aggregator by introducing a separate parent project (being the parent
>> for all other projects). This way, the aggreagtor is able to have
>> dependencies on its children projects and the jacoco aggregate report
>> can be generated inside the aggregator, too.
>> 
>> Am 05.05.2025 21:24 schrieb [email protected]:
>> > Hello!
>> >
>> > Let's assume I have three Maven artifacts: One aggregating parent
>> > artifact and two children modules.
>> >
>> > I'd like to generate an aggregating report both for jacoco and pmd,
>> > each comprising both children modules. I'd like those two aggregatings
>> > reports to be located in the same Maven artifact. Is this possible?
>> >
>> > [1] says regarding "jacoco:report-aggregate": "Creates a structured
>> > code coverage report [...] from multiple projects within reactor. The
>> > report is created from all modules this project depends on [...]."
>> > [2] says regarding "pmd:aggregate-pmd": "Creates a PMD site report in
>> > an aggregator project [...]".
>> >
>> > This doesn't work well together, does it? An aggregating PMD report
>> > has to be in an aggregator project, but jacoco would need the
>> > aggregator project to depend on the two children, which doesn't work.
>> >
>> > In fact, I managed to create an aggregating report for jacoco by
>> > introducing another child-report module which depends on the other two
>> > children modules, and I managed to create an aggregating report for
>> > PMD inside the aggregating parent artifact, but I couldn't make both
>> > reports to be in the same artifact.
>> >
>> > I'd like to make sure that I'm not maybe missing something or if this
>> > indeed is not possible. The reason I'm asking is because to me it
>> > feels a bit clumsy that when generating a Maven site for the
>> > aforementioned structure one has two consult two different places
>> > inside this site to see all aggregating reports.
>> >
>> > [1] https://www.eclemma.org/jacoco/trunk/doc/report-aggregate-mojo.html
>> > [2]
>> > https://maven.apache.org/plugins/maven-pmd-plugin/aggregate-pmd-mojo.html
>> >
>> > Best regards
>> > Tobias
>> >
>> > ---------------------------------------------------------------------
>> > To unsubscribe, e-mail: [email protected]
>> > For additional commands, e-mail: [email protected]
>> 
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: [email protected]
>> For additional commands, e-mail: [email protected]
>> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.