diff options
author | Matthias Sohn <matthias.sohn@sap.com> | 2015-03-09 15:57:48 -0700 |
---|---|---|
committer | Christian Halstrick <christian.halstrick@sap.com> | 2015-03-23 09:52:22 -0400 |
commit | dd453f4185c8e7e9608605a35abd4ac4eaadba76 (patch) | |
tree | 3e6932d2a9f246891094a5b8457f8c9218fdbcd0 /org.eclipse.jgit.pgm | |
parent | 197e3393a51424fae45e51dce4a649ba26e5a368 (diff) | |
download | jgit-dd453f4185c8e7e9608605a35abd4ac4eaadba76.tar.gz jgit-dd453f4185c8e7e9608605a35abd4ac4eaadba76.zip |
Include slf4j and log4j in jgit command line
This enables the command line to log. Include log4j configuration to log
warnings and errors to stderr.
Exclude the dependencies which log4j 1.2.15 should have marked optional.
See
http://unitstep.net/blog/2009/05/18/resolving-log4j-1215-dependency-problems-in-maven-using-exclusions/
for details
Change-Id: Ie730db4007fb7614fd7d130cd0858b1ac550066a
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
Diffstat (limited to 'org.eclipse.jgit.pgm')
-rw-r--r-- | org.eclipse.jgit.pgm/pom.xml | 18 | ||||
-rw-r--r-- | org.eclipse.jgit.pgm/resources/log4j.properties | 6 |
2 files changed, 24 insertions, 0 deletions
diff --git a/org.eclipse.jgit.pgm/pom.xml b/org.eclipse.jgit.pgm/pom.xml index 2bc11e8b9a..52cd0a3f26 100644 --- a/org.eclipse.jgit.pgm/pom.xml +++ b/org.eclipse.jgit.pgm/pom.xml @@ -93,6 +93,24 @@ <artifactId>org.eclipse.jgit.ui</artifactId> <version>${project.version}</version> </dependency> + + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-api</artifactId> + <version>${slf4j-version}</version> + </dependency> + + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-log4j12</artifactId> + <version>${slf4j-version}</version> + </dependency> + + <dependency> + <groupId>log4j</groupId> + <artifactId>log4j</artifactId> + <version>${log4j-version}</version> + </dependency> </dependencies> <build> diff --git a/org.eclipse.jgit.pgm/resources/log4j.properties b/org.eclipse.jgit.pgm/resources/log4j.properties new file mode 100644 index 0000000000..4a2e48011a --- /dev/null +++ b/org.eclipse.jgit.pgm/resources/log4j.properties @@ -0,0 +1,6 @@ +log4j.rootLogger=WARNING, stderr + +log4j.appender.stderr=org.apache.log4j.ConsoleAppender +log4j.appender.stderr.Target=System.err +log4j.appender.stderr.layout=org.apache.log4j.PatternLayout +log4j.appender.stderr.layout.ConversionPattern=%d{yyyy-MM-dd HH:mm:ss} %-5p %c{1}:%L - %m%n
\ No newline at end of file |