I have a project which uses log4j for logging. We have a log4j.xml file which controls the log level. I would like to have another log4j.local.xml which I plan to add to gitignore file that takes precedence over normal log4j.xml once it is present. This was on local builds, I can have a log level set to my liking but once the project is checked in and built (on Jenkins for example) and deployed normal log4j.xml setting get used since log4j.local.xml will not be there.
EDIT: Application does not have any configuration to specify settings file or anything for log4j. I assume the logging framework has some defaults that are being used. Also, application is using Java code for Spring configuration and not an XML file.