My experience is that the runtime model is the effective pom; in contrast, the original model is what is reflected in the pom file.
Matt On Wed, Dec 22, 2021, 2:05 PM Sebastian Proksch <sebast...@proks.ch> wrote: > Dear all, > > I am currently programmatically working on some poms, mainly to find > some information in the files to generate some "summaries". I found > the "maven-model" project of Apache Commons that made it so much > easier to access the contents of a single file, but supporting the > inheritance of parent poms or the resolution of property references is > yet another beast and it is challenging to implement a general > solution from scratch. > > I know about "mvn help:effective-pom" which can be used on the > terminal to debug a Maven config. It will consider all factors that > play a role when interpreting a pom file and merges everything into > one file. It seems that I could just use this as "preprocessing" and > completely avoid the need for complicating my parser. Unfortunately, > it is not possible for me to run terminal utilities in my task and I > need a programmatic (Java) solution... > > Does anybody know whether the logic of "help:effective-pom" is exposed > somewhere through an API? Or is there a "maven-model++" that can > automatically consider parent poms? > Any pointers are appreciated! Thanks! > > best > Sebastian > > --------------------------------------------------------------------- > To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org > For additional commands, e-mail: dev-h...@maven.apache.org > >