Also note that there is one exception to this rule, ${project.basedir}
can be used in the repository url.

Le sam. 21 déc. 2024 à 23:02, Tamás Cservenák <ta...@cservenak.net> a écrit :
>
> Howdy,
>
> yes, POM must contain "non-dynamic" URL, this is due build reproducibility.
> You can add a repository via settings.xml, and now you can have
> "project wide settings" as well.
>
> Thanks
> T
>
> On Sat, Dec 21, 2024 at 8:48 PM Andreas Kuhtz <andreas.ku...@gmail.com> wrote:
> >
> > Hello,
> >
> > With maven 3.9.x it was possible to configure to configure an additional
> > repository for artefacts not available in central repo or artefacts that
> > are not allowed to be published to central repo with the following file url:
> >
> > <repositories>
> > ...
> >         <!--
> >         Repository hosting libraries not available through maven.org
> >         -->
> >         <repository>
> >             <id>lib</id>
> >             <name>lib</name>
> >             <releases>
> >                 <enabled>true</enabled>
> >                 <checksumPolicy>ignore</checksumPolicy>
> >             </releases>
> >             <snapshots>
> >                 <enabled>true</enabled>
> >             </snapshots>
> >
> > <url>file://${maven.multiModuleProjectDirectory}/maven-repo</url>
> >         </repository>
> > ...
> > </repositories>
> >
> > With 4.0.0-rc-2 this is no longer possible and the build fails with the
> > following error:
> >
> > [INFO]
> > [INFO] Some problems were encountered while building the effective settings
> > (use -X to see details)
> > [INFO]
> > [INFO] Scanning for projects...
> > [ERROR] Some problems were encountered while processing the POMs
> > [ERROR] The build could not read 1 project -> [Help 1]
> > [ERROR]
> > [ERROR]   The project [inherited]:wizard:pom:[inherited]
> > (D:\gitlab\bidibwizard2-distributed\pom.xml) has 2 errors
> > [ERROR]     'repositories.repository.[lib].url' contains an expression but
> > should be a constant. @ org.bidib.jbidib:bidibwizard-parent:${revision},
> > file:///D:/gitlab/bidibwizard2-distributed/bidibwizard-parent/pom.xml, line
> > 68, column 13
> > [ERROR]     'repositories.repository.[lib].url' contains an expression but
> > should be a constant. @ org.bidib.jbidib:bidibwizard-parent:${revision},
> > file:///D:/gitlab/bidibwizard2-distributed/bidibwizard-parent/pom.xml, line
> > 68, column 13
> > [ERROR]
> >
> > How can this be solved?
> >
> > Cheers,
> > Andreas
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
> For additional commands, e-mail: users-h...@maven.apache.org
>


-- 
------------------------
Guillaume Nodet

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org

Reply via email to