Hi Andreas,

you could put it literally everywehre (e.g. the .mvn folder) and
reference it via "-s" parameter to be used. So you could put it into the
projects repo.

Greetings

Matthias

Am 22.12.2024 um 08:43 schrieb Andreas Kuhtz:
Hello,
Yes, settings.xml is an option but then I have to let every developer add
this repo to settings.xml that is used for this project only.
Can you give me a pointer where to find information about "project wide
settings"?

Cheers,
Andreas

Am Sa., 21. Dez. 2024 um 23:02 Uhr schrieb Tamás Cservenák <
ta...@cservenak.net>:

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



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

Reply via email to