@Tamás: Right, should had explained the use case. I want to deploy all
artifacts to a local directory so that I can inspect everything which will
be deployed given certain conditions.
I managed to do that by forcing a stable, absolute directory as shown at

https://github.com/moditect/layrry/pull/90/commits/93472049fee1b5ffa579929211aac20bef3f5e00

I'd prefer if the target directory be ${rootProject.build.directory} if
there were such things as {$rootProject}, which is why I'm asking for a way
to find out that value.
As you may appreciate in that commit the value is used as part of
<distributionManagement> in a profile.

@Lasse: I thought using that plugin would work but not in my case as the
computed property is not available during model interpolation which is my
case for setting the correct value in <distributionManagement>

Cheers,
Andres

-------------------------------------------
Java Champion; Groovy Enthusiast
http://andresalmiray.com
http://www.linkedin.com/in/aalmiray
--
What goes up, must come down. Ask any system administrator.
There are 10 types of people in the world: Those who understand binary, and
those who don't.
To understand recursion, we must first understand recursion.


On Fri, Feb 5, 2021 at 6:32 PM Lasse Lindqvist <lasse.k.lindqv...@gmail.com>
wrote:

> Using directory-maven-plugin and highest-basedir goal from it has worked
> just fine for me.
> https://github.com/jdcasey/directory-maven-plugin#highest-basedir-goal
>
> pe 5. helmik. 2021 klo 18.53 Tamás Cservenák (ta...@cservenak.net)
> kirjoitti:
>
> > Howdy,
> > Grab somehow (you did not state from where if "outside of plugins")
> > MavenSession, it has getExecutionRootDirectory method, BUT it may not be
> > what you want, as one may use -f param for example...
> >
> > So, I'd shoot back: WHY do you need the root of a multi module build and
> > FROM WHAT you need it? Extension?
> > Are you sure you can expect maven is invoked from root? Could it be
> simpler
> > just to pass in as some parameter maybe, instead of doing all sorts of
> > hoops and loops?
> >
> > T
> >
> > On Fri, Feb 5, 2021 at 5:04 PM Andres Almiray <aalmi...@gmail.com>
> wrote:
> >
> > > Hello everyone,
> > >
> > > Is there a way to reliably resolve the value of the root directory for
> a
> > > given multi-project build?
> > > Unfortunately ${session.executionRootDirectory} does not seem to work
> for
> > > all cases, it might work when used inside a plugin's <configuration>
> > > section but does not when used outside of plugins
> > >
> > > TIA
> > >
> > > Cheers,
> > > Andres
> > >
> > > -------------------------------------------
> > > Java Champion; Groovy Enthusiast
> > > http://andresalmiray.com
> > > http://www.linkedin.com/in/aalmiray
> > > --
> > > What goes up, must come down. Ask any system administrator.
> > > There are 10 types of people in the world: Those who understand binary,
> > and
> > > those who don't.
> > > To understand recursion, we must first understand recursion.
> > >
> >
>

Reply via email to