maven línea de comandos cómo apuntar a una configuración específica.xml para un solo comando?


¿Es posible apuntar a un archivo de configuración específico para anular la configuración predeterminada?xml utilizado por maven para un solo comando? Ejemplo:

mvn clean install -Dparam # -> pass specific settings file path as param to override default "home/.m2/settings.xml"
Author: guilhebl, 2014-08-13

2 answers

Simplemente puede usar:

mvn --settings YourOwnSettings.xml clean install

O

mvn -s YourOwnSettings.xml clean install
 124
Author: khmarbaise,
Warning: date(): Invalid date.timezone value 'Europe/Kyiv', we selected the timezone 'UTC' for now. in /var/www/agent_stack/data/www/ajaxhispano.com/template/agent.layouts/content.php on line 61
2014-08-13 06:22:12

@ Neeraj Singh Chouhan: En Eclipse Vaya a Preferencias -> Maven -> UserSettings -> Busque YourOwnSettings.XML Haga clic en Aceptar

 -5
Author: user3929026,
Warning: date(): Invalid date.timezone value 'Europe/Kyiv', we selected the timezone 'UTC' for now. in /var/www/agent_stack/data/www/ajaxhispano.com/template/agent.layouts/content.php on line 61
2017-12-14 15:21:05