You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by cs...@apache.org on 2022/09/10 09:31:12 UTC

[maven-mvnd] branch issue-685-coloring-on-transfer created (now 1511066)

This is an automated email from the ASF dual-hosted git repository.

cstamas pushed a change to branch issue-685-coloring-on-transfer
in repository https://gitbox.apache.org/repos/asf/maven-mvnd.git


      at 1511066  Fixes module id coloring on Maven transfer.

This branch includes the following new commits:

     new 1511066  Fixes module id coloring on Maven transfer.

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.



[maven-mvnd] 01/01: Fixes module id coloring on Maven transfer.

Posted by cs...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

cstamas pushed a commit to branch issue-685-coloring-on-transfer
in repository https://gitbox.apache.org/repos/asf/maven-mvnd.git

commit 1511066266f25401dea52e1d351378137bd9c16c
Author: Tamas Cservenak <ta...@cservenak.net>
AuthorDate: Sat Sep 10 11:30:28 2022 +0200

    Fixes module id coloring on Maven transfer.
    
    The module id coloring was not consistent during transfer
    and it caused "vibrating" effect.
---
 .../main/java/org/mvndaemon/mvnd/common/logging/TerminalOutput.java | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/common/src/main/java/org/mvndaemon/mvnd/common/logging/TerminalOutput.java b/common/src/main/java/org/mvndaemon/mvnd/common/logging/TerminalOutput.java
index 89c688e..46e1a06 100644
--- a/common/src/main/java/org/mvndaemon/mvnd/common/logging/TerminalOutput.java
+++ b/common/src/main/java/org/mvndaemon/mvnd/common/logging/TerminalOutput.java
@@ -90,6 +90,7 @@ public class TerminalOutput implements ClientOutput {
 
     private static final AttributedStyle GREEN_FOREGROUND = new AttributedStyle().foreground(AttributedStyle.GREEN);
     private static final AttributedStyle CYAN_FOREGROUND = new AttributedStyle().foreground(AttributedStyle.CYAN);
+    private static final AttributedStyle WHITE_FOREGROUND = new AttributedStyle().foreground(AttributedStyle.WHITE);
 
     private final Terminal terminal;
     private final Terminal.SignalHandler previousIntHandler;
@@ -767,12 +768,15 @@ public class TerminalOutput implements ClientOutput {
         if (transfer != null) {
             asb
                     .append(':')
+                    .style(CYAN_FOREGROUND)
                     .append(String.format(artifactIdFormat, prj.id))
+                    .style(WHITE_FOREGROUND)
                     .append(transfer);
         } else if (execution == null) {
             asb
                     .append(':')
-                    .append(prj.id);
+                    .style(CYAN_FOREGROUND)
+                    .append(String.format(artifactIdFormat, prj.id));
         } else {
             asb
                     .append(':')