Maven: specify location of settings.xml in pom.xml?

Is it possible to set the location of the file settings.xmlinside the file pom.xml.

I know that you can do this from the command line by typing mvn -s location/of/settings.xml, but I wanted to know if I can install this in pom.xml, so I do not need to continue typing through the command line.

+5
source share
3 answers

No. And this is probably a terrible idea from a security point of view. This would allow the pom creator to get around all your settings.xml settings. If you follow mvn -s location/of/settings.xml, you will at least find out what happened. But if you just arbitrarily create a project, who knows how evil the creator of the project is.

+1

, , , settings.xml pom.xml, settings.xml

0

-, , , profiles:

Maven - ,      . ,      . pom.xml     . Maven , Maven      . pom.xml      .

: http://maven.apache.org/pom.html#Profiles

0
source

All Articles