File tree Expand file tree Collapse file tree 4 files changed +18
-3
lines changed
src/main/java/pl/project13/maven/git Expand file tree Collapse file tree 4 files changed +18
-3
lines changed Original file line number Diff line number Diff line change @@ -305,8 +305,8 @@ public void execute() throws MojoExecutionException {
305305 prefixDot = prefix + "." ;
306306
307307 loadGitData (properties );
308- filterNot (properties , excludeProperties );
309308 loadBuildTimeData (properties );
309+ filterNot (properties , excludeProperties );
310310 logProperties (properties );
311311
312312 if (generateGitPropertiesFile ) {
@@ -316,7 +316,7 @@ public void execute() throws MojoExecutionException {
316316 if (injectAllReactorProjects ) {
317317 appendPropertiesToReactorProjects (properties );
318318 }
319- } catch (IOException e ) {
319+ } catch (Exception e ) {
320320 handlePluginFailure (e );
321321 }
322322
@@ -340,7 +340,7 @@ public Predicate<CharSequence> apply(String exclude) {
340340
341341 for (String key : properties .stringPropertyNames ()) {
342342 if (shouldExclude .apply (key )) {
343- System . out . println ("shouldExclude.apply(" + key +") = " + shouldExclude .apply (key ));
343+ loggerBridge . debug ("shouldExclude.apply(" + key +") = " + shouldExclude .apply (key ));
344344 properties .remove (key );
345345 }
346346 }
Original file line number Diff line number Diff line change 2020public interface LoggerBridge {
2121 void log (Object ... parts );
2222 void error (Object ... parts );
23+ void debug (Object ... parts );
2324 void setVerbose (boolean verbose );
2425}
Original file line number Diff line number Diff line change @@ -43,6 +43,13 @@ public void error(Object... parts) {
4343 logger .error (Joiner .on (" " ).join (parts ));
4444 }
4545 }
46+
47+ @ Override
48+ public void debug (Object ... parts ) {
49+ if (verbose ) {
50+ logger .debug (Joiner .on (" " ).join (parts ));
51+ }
52+ }
4653
4754 @ Override
4855 public void setVerbose (boolean verbose ) {
Original file line number Diff line number Diff line change @@ -40,6 +40,13 @@ public void error(Object... parts) {
4040 System .out .println ("ERR: " + Joiner .on (" " ).join (parts ));
4141 }
4242 }
43+
44+ @ Override
45+ public void debug (Object ... parts ) {
46+ if (verbose ) {
47+ System .out .println ("DBG: " + Joiner .on (" " ).join (parts ));
48+ }
49+ }
4350
4451 @ Override
4552 public void setVerbose (boolean verbose ) {
You can’t perform that action at this time.
0 commit comments