You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Olivier Lamy <ol...@accor.com> on 2006/05/12 09:34:42 UTC

RE : log4j config file and mvn

If logging.xml is just needed for test purpose, put it in
src/test/resources in a module.
I think I will be used in first by surefire.

You can create a module called by example ${artifactId}-config
(packaging jar) which contains all default configuration in
src/main/resources. (put it in the top of modules list).
Then use it as a dependency scope=test in the others modules.
Perso, I do as this (a module with default configuration which is
include as test dependency).
Then to override it I put the files in src/test/resources in modules.

-Olivier



-----Message d'origine-----
De : davisford@gmail.com [mailto:davisford@gmail.com] De la part de
Davis Ford
Envoyé : vendredi 12 mai 2006 02:52
À : Maven Users List
Objet : log4j config file and mvn


Hi, I was wondering if someone might be able to describe how to solve
the following problem:

We have one master project pom.xml that has <module></module> in it.

A team can check out a <module> that has its own pom.xml and build it
independently.  At the end of the day, the master pom.xml builds all
subprojects and runs integration tests.

There is one subproject called logging that controls logging for the
project using log4j.  It has a logging.xml file as a resource. However,
each developer will want to tweak the logging.xml file to his/her tastes
while developing.

What I would like to do is set the logging.xml file as a resource of the
master project, and then have the logging subproject use that file (if
it exists), or if it does not exist, default to its own logging.xml
resource file.

This would allow a developer to edit the master project logging.xml for
their local builds, and have the logging.jar reference that.

How can I accomplish this in mvn, or is there a better way to achieve
the end goal?

Thx,
Davis

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



This e-mail, any attachments and the information contained therein ("this message") are confidential and intended solely for the use of the addressee(s). If you have received this message in error please send it back to the sender and delete it. Unauthorized publication, use, dissemination or disclosure of this message, either in whole or in part is strictly prohibited.
--------------------------------------------------------------------------------------------------------------
Ce message électronique et tous les fichiers joints ainsi que  les informations contenues dans ce message ( ci après "le message" ), sont confidentiels et destinés exclusivement à l'usage de la  personne à laquelle ils sont adressés. Si vous avez reçu ce message par erreur, merci  de le renvoyer à son émetteur et de le détruire. Toutes diffusion, publication, totale ou partielle ou divulgation sous quelque forme que se soit non expressément autorisées de ce message, sont interdites.
-------------------------------------------------------------------------------------------------------------


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