Thanks to all who has contributed in this thread.

Here is the final result, see attached picture.
Now there are colors but the entire line of test result is not one
color/green which was previously shining to you eyes in every line.
If the Users group requires customizing the outcome, we can still continue
in Jira, and we can implement proposed solution
defining *.properties file with formatter using placeholders like "Tests
run: {0}, ", using native colors etc.
I still think Surefire can have config parameter and configured via system
property globally in ".mvn/jvm.config" and we do not need to do anything in
Maven as a kind of generic solution for every Maven plugin would not be
realistic only because of requirements from Surefire.


On Mon, Sep 12, 2016 at 10:57 PM, Robert Scholte-6 [via Maven] <
ml-node+s40175n5880539...@n5.nabble.com> wrote:

> On Mon, 12 Sep 2016 21:50:42 +0200, Hervé BOUTEMY <[hidden email]
> <http:///user/SendEmail.jtp?type=node&node=5880539&i=0>>
> wrote:
>
> > I really doubt plugins will be documented to give anybody any chance to
>
> > learn
> > how to configure such details. And even with documentation, I doubt
> > anybody
> > will take time to configure his Maven install
> >
> > But if you really want to do this, you should improve the MessageBuilder
>
> > API
> > [1] to add styles in text patterns: something like replacing "%failure%"
>
> > with
> > failure style, and choosing a pattern for resetting color
> >
> >
> > But once again, I doubt such deep configuration really makes sense: so
> > few
> > people will know how to use it
>
> +1, fully agree. *IF* this should be done, which I really doubt, it should
>
> be at Maven level, not at plugin level.
>
> Robert
>
> >
> > Regards,
> >
> > Hervé
> >
> >
> > [1]
> > https://maven.apache.org/shared-archives/maven-shared-
> utils-LATEST/apidocs/org/apache/maven/shared/utils/
> logging/MessageBuilder.html
> >
> >
> > Le lundi 12 septembre 2016 09:37:50 Romain Manni-Bucau a écrit :
> >> 2016-09-12 9:30 GMT+02:00 Tibor Digana <[hidden email]
> <http:///user/SendEmail.jtp?type=node&node=5880539&i=1>>:
> >> > >>If you compare maven to dome
> >> >
> >> > Although we do not have DOM this inspires me to define *.properties
> >> with
> >> > formatter using placeholders
> >> > success = [m32 Tests run: %1, Failure: %2, Errors: %3, Skipped: %4;
> >> > etc.
> >> > In this case we do not need to use JAnsi library in Surefire's code
> >> and
> >> > text including colors can be customized.
> >> > I doubt Maven core would provide Surefire with such interface, why
> >> only
> >> > this plugin and not the other as well.
> >>
> >> +1, nice to have is some aliases for colors instead of unix
> >> \[\033[01;34m\]
> >> etc.
> >>
> >> This needs a default global config based on level I think customizable
>
> >> per
> >> plugin (=overridable for some lines, maybe through a MDC to give the
> >> key to
> >> read?).
> >>
> >> > On Sat, Sep 10, 2016 at 1:29 PM, Romain Manni-Bucau
> >> <[hidden email] <http:///user/SendEmail.jtp?type=node&node=5880539&i=2>
> >> >
> >> > wrote:
> >> > > Le 10 sept. 2016 12:57, "Hervé BOUTEMY" <[hidden email]
> <http:///user/SendEmail.jtp?type=node&node=5880539&i=3>> a
> >> écrit
> >> > >
> >> > > > Le vendredi 9 septembre 2016 10:49:54 Tibor Digana a écrit :
> >> > > > > @Herve What do you think about Romain's concept:
> >> --color-info=blue
> >> > > > > --color-error=red --color-warning=yellow-bold
> >> > > > > @Romain In MVN 3.4 you can override the colors via system
> >> > > > > properties,
> >> > >
> >> > > e.g.
> >> > >
> >> > > > > -Dstyle.info=bold,blue
> >> > > >
> >> > > > see
> >> > >
> >> > > http://maven.apache.org/shared/maven-shared-utils/
> >> > > apidocs/org/apache/maven/shared/utils/logging/package-summary.html
> >> > >
> >> > > > > @Romain, if we had "--color-surefire-test=blue" in CLI then all
> >> >
> >> > plugins
> >> >
> >> > > > > would require to have the same principle.
> >> > > > > What if some users want to cover only some part of the text
> with
> >> >
> >> > colors
> >> >
> >> > > and
> >> > >
> >> > > > > combine with multiple colors?
> >> > > >
> >> > > > making styles rendering configurable per plugin seems really too
>
> >> much,
> >> > >
> >> > > IMHO
> >> > >
> >> > >
> >> > > If you compare maven to dome other build tools you have more data
> >> you
> >> > > can
> >> > > desire to control *as a user*: level, message, subpart of a message
>
> >> etc.
> >> > > Control per line or data etc...
> >> > >
> >> > > This induce the need of more config by nature otherwise colors are
> a
> >> > > less
> >> > > useful feature than it should be cause instead of helping the user
> >> > > making
> >> > > outputs more readable you decrease the readability. That is my
> >> feedback
> >> > > with current colors and why i forked the binder ATM.
> >> > >
> >> > > > Regards,
> >> > > >
> >> > > > Hervé
> >> > > >
> >> > > > > On Fri, Sep 9, 2016 at 10:06 AM, Romain Manni-Bucau <
> >> > >
> >> > > [hidden email]
> <http:///user/SendEmail.jtp?type=node&node=5880539&i=4>>
> >> > >
> >> > > > > wrote:
> >> > > > > > 2016-09-09 7:45 GMT+02:00 Tibor Digana <
> >> >
> >> > [hidden email]
> <http:///user/SendEmail.jtp?type=node&node=5880539&i=5>
> >> >
> >> > > > > > > Romain, did you mean
> >> ${maven.projectBasedir}/.mvn/maven.config
> >> > >
> >> > > [1] ?
> >> > >
> >> > > > > > > Some extension or maven.config.
> >> > > > > > > [1] https://maven.apache.org/docs/3.3.1/release-notes.html
> >> > > > > >
> >> > > > > > Could be if all options are mapped to the command line but
> was
> >> > > > > > more
> >> > > > > > thinking to a color oriented config (globally and overridable
>
> >> by
> >> > >
> >> > > plugin)
> >> > >
> >> > > > > > In maven config it would be something like:
> >> > > > > >     --color-info=blue --color-error=red
> >> > > > > >     --color-warning=yellow-bold
> >> > > > > >
> >> > > > > > etc.... --color-surefire-test=blue
> >> > > > > >
> >> > > > > > Not a "syntax" I'm in love but in the home and working so
> >> would be
> >> >
> >> > ok
> >> >
> >> > > too
> >> > >
> >> > > > > > > On Fri, Sep 9, 2016 at 12:20 AM, Romain Manni-Bucau <
> >> > > > > >
> >> > > > > > [hidden email]
> <http:///user/SendEmail.jtp?type=node&node=5880539&i=6>
> >> > > > > >
> >> > > > > > > wrote:
> >> > > > > > > > Color is a user thing not a build thing so belongs to .m2
>
> >> not
> >> > > > > > > > <configuration> I think.
> >> > > > > > > >
> >> > > > > > > > Le 9 sept. 2016 00:18, "Gary Gregory"
> >> <[hidden email] <http:///user/SendEmail.jtp?type=node&node=5880539&i=7>>
>
> >> >
> >> > a
> >> >
> >> > > > > > écrit :
> >> > > > > > > > > On Thu, Sep 8, 2016 at 2:48 PM, Romain Manni-Bucau <
> >> > > > > > > >
> >> > > > > > > > [hidden email]
> <http:///user/SendEmail.jtp?type=node&node=5880539&i=8>>
> >> > > > > > > >
> >> > > > > > > > > wrote:
> >> > > > > > > > > > +1 to remove the bold
> >> > > > > > > > >
> >> > > > > > > > > I agree fwiw.
> >> > > > > > > > >
> >> > > > > > > > > Gary
> >> > > > > > > > >
> >> > > > > > > > > > What about having the coloration configurable in
> >> > >
> >> > > settings.xml:
> >> > > > > > > current
> >> > > > > > >
> >> > > > > > > > or
> >> > > > > > > >
> >> > > > > > > > > > no color for test result line or single color for
> >> level
> >> > > > > > > > > > and
> >> > >
> >> > > result
> >> > >
> >> > > > > > or
> >> > > > > >
> >> > > > > > > > > only
> >> > > > > > > > >
> >> > > > > > > > > > start of the line?
> >> > > > > > > > > >
> >> > > > > > > > > > Le 8 sept. 2016 23:36, "Tibor Digana" <
> >> > >
> >> > > [hidden email]
> <http:///user/SendEmail.jtp?type=node&node=5880539&i=9>>
> >> > > a
> >> > >
> >> > > > > > > > écrit :
> >> > > > > > > > > > > sending the picture in attachment..
> >> > > > > > > > > > >
> >> > > > > > > > > > > On Thu, Sep 8, 2016 at 11:32 PM, Romain Manni-Bucau
>
> >> [via
> >> > >
> >> > > Maven]
> >> > >
> >> > > > > > > > > > > <
> >> > > > > > > > > > >
> >> > > > > > > > > > > [hidden email]
> <http:///user/SendEmail.jtp?type=node&node=5880539&i=10>> wrote:
> >> > > > > > > > > > > > Hello Tibor,
> >> > > > > > > > > > > >
> >> > > > > > > > > > > > not sure that's me but I don't see the picture
> >> > > > > > > > > > > >
> >> > > > > > > > > > > > that said I like this kind of coloring for maven:
> >> > > > > > > > > > > > https://raw.githubusercontent.
> >> > >
> >> > > com/rmannibucau/maven-color/
> >> > >
> >> > > > > > > > > > > > master/screenshot.png
> >> > > > > > > > > > > > . Makes it easy to identify steps and warn/error
>
> >> (in
> >> >
> >> > red)
> >> >
> >> > > > > > > visually
> >> > > > > > >
> >> > > > > > > > > > > > Romain Manni-Bucau
> >> > > > > > > > > > > > @rmannibucau <https://twitter.com/rmannibucau> |
>
> >> Blog
> >> > > > > > > > > > > > <https://blog-rmannibucau.rhcloud.com> | Old
> >> Wordpress
> >> > >
> >> > > Blog
> >> > >
> >> > > > > > > > > > > > <http://rmannibucau.wordpress.com> | Github <
> >> > > > > >
> >> > > > > > https://github.com/
> >> > > > > >
> >> > > > > > > > > > > > rmannibucau> |
> >> > > > > > > > > > > > LinkedIn
> >> <https://www.linkedin.com/in/rmannibucau> |
> >> > > > > >
> >> > > > > > Tomitriber
> >> > > > > >
> >> > > > > > > > > > > > <http://www.tomitribe.com> | JavaEE Factory
> >> > > > > > > > > > > > <https://javaeefactory-rmannibucau.rhcloud.com>
> >> > > > > > > > > > > >
> >> > > > > > > > > > > > 2016-09-08 23:27 GMT+02:00 Tibor Digana <[hidden
> >> > > > > > > > > > > > email]
> >> > > > > > > > > > > >
> >> > > > > > > > > > > > <http:///user/SendEmail.jtp?
> >> > >
> >> > > type=node&node=5880220&i=0>>:
> >> > > > > > > > > > > > > Currently the colored console looks like in the
> >> > >
> >> > > picture.
> >> > >
> >> > > > > > > > > > > > > Please let me know what other highlighting you
> >> >
> >> > prefer.
> >> >
> >> > > > > > > > > > > > > I do not prefer using bold text in color, and
> >> use
> >> > >
> >> > > colors
> >> > >
> >> > > > > > > > > > > > > only
> >> > > > > > >
> >> > > > > > > in
> >> > > > > > >
> >> > > > > > > > > the
> >> > > > > > > > >
> >> > > > > > > > > > > > begin
> >> > > > > > > > > > > >
> >> > > > > > > > > > > > > of line:
> >> > > > > > > > > > > > > "Tests run: 12, Failure: 0, Errors: 0, Skipped:
>
> >> 0"
> >> > > > > > > > > > > > >
> >> > > > > > > > > > > > > WDYT?
> >> > > > > > > > > > > > >
> >> > > > > > > > > > > > > I will not change the text.
> >> > > > > > > > > > > > >
> >> > > > > > > > > > > > > [image: Inline image 1]
> >> > > > > > > > > > > > >
> >> > > > > > > > > > > > > --
> >> > > > > > > > > > > > > Cheers
> >> > > > > > > > > > > > > Tibor
> >> > > > > > > > > > > >
> >> > > > > > > > > > > > ------------------------------
> >> > > > > > > > > > > > If you reply to this email, your message will be
>
> >> added
> >> >
> >> > to
> >> >
> >> > > the
> >> > >
> >> > > > > > > > > > discussion
> >> > > > > > > > > >
> >> > > > > > > > > > > > below:
> >> > > > > > > > > > > >
> >> http://maven.40175.n5.nabble.com/colored-console-> >
> >> > > > > > > > > >
> >> > > > > > > > > > tp5880214p5880220.html
> >> > > > > > > > > >
> >> > > > > > > > > > > > To start a new topic under Maven Developers,
> email
> >> > > > > > > > > > > > [hidden email]
> <http:///user/SendEmail.jtp?type=node&node=5880539&i=11>
> >> > > > > > > > > > > > To unsubscribe from Maven Developers, click here
> >> > > > > > > > > > > > <http://maven.40175.n5.nabble.
> >> > >
> >> > > com/template/NamlServlet.jtp
> >> > > ?
> >> > >
> >> > > > > > > > > > > macro=unsubscribe_by_code&node=142166&code=
> >> > > > > > > > > >
> >> > > > > > > > > > dGlib3JkaWdhbmFAYXBhY2hlLm9yZ3
> >> > > > > > > > > >
> >> > > > > > > > > > > wxNDIxNjZ8LTI4OTQ5MjEwMg==>
> >> > > > > > > > > > >
> >> > > > > > > > > > > > .
> >> > > > > > > > > > > > NAML
> >> > > > > > > > > > > > <http://maven.40175.n5.nabble.
> >> > >
> >> > > com/template/NamlServlet.jtp
> >> > > ?
> >> > >
> >> > > > > > > > > > > macro=macro_viewer&id=instant_
> >> >
> >> > html%21nabble%3Aemail.naml&
> >> >
> >> > > > > > > > > > >
> >> base=nabble.naml.namespaces.BasicNamespace-nabble.view.
> >> > > > > > > > > > >
> >> web.template.NabbleNamespace-nabble.view.web.template.
> >> > > > > > > > > > >
> >> NodeNamespace&breadcrumbs=notify_subscribers%21nabble%
> >> > > > > > > > > > >
> >> 3Aemail.naml-instant_emails%21nabble%3Aemail.naml-send_
> >> > > > > > > > > > > instant_email%21nabble%3Aemail.naml>
> >> > > > > > > > > > >
> >> > > > > > > > > > >
> >> > > > > > > > > > >
> >> > > > > > > > > > > SUREFIRE-1254.png (198K)
> >> <http://maven.40175.n5.nabble.
> >> > > > > > > > > > > com/attachment/5880221/0/SUREFIRE-1254.png>
> >> > > > > > > > > > >
> >> > > > > > > > > > >
> >> > > > > > > > > > >
> >> > > > > > > > > > >
> >> > > > > > > > > > > --
> >> >
> >> > > > > > > > > > > View this message in context:
> >> > http://maven.40175.n5.nabble
> >> >
> >> > > .
> >> > >
> >> > > > > > > > > > > com/colored-console-tp5880214p5880221.html
> >> > > > > > > > > > > Sent from the Maven Developers mailing list archive
>
> >> at
> >> > > > > >
> >> > > > > > Nabble.com.
> >> > > > > >
> >> > > > > > > > > --
> >> > > > > > > > > E-Mail: [hidden email]
> <http:///user/SendEmail.jtp?type=node&node=5880539&i=12> | [hidden email]
> <http:///user/SendEmail.jtp?type=node&node=5880539&i=13>
> >> > > > > > > > > Java Persistence with Hibernate, Second Edition
> >> > > > > > > > > <http://www.manning.com/bauer3/>
> >> > > > > > > > > JUnit in Action, Second Edition <
> >> > >
> >> > > http://www.manning.com/tahchiev/>
> >> > >
> >> > > > > > > > > Spring Batch in Action
> >> <http://www.manning.com/templier/>
> >> > > > > > > > > Blog: http://garygregory.wordpress.com
> >> > > > > > > > > Home: http://garygregory.com/
> >> > > > > > > > > Tweet! http://twitter.com/GaryGregory
> >> > > > > > >
> >> > > > > > > --
> >> > > > > > > Cheers
> >> > > > > > > Tibor
> >> > > >
> >> > > >
> >> ---------------------------------------------------------------------
> >> > > > To unsubscribe, e-mail: [hidden email]
> <http:///user/SendEmail.jtp?type=node&node=5880539&i=14>
> >> > > > For additional commands, e-mail: [hidden email]
> <http:///user/SendEmail.jtp?type=node&node=5880539&i=15>
> >> >
> >> > --
> >> > Cheers
> >> > Tibor
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [hidden email]
> <http:///user/SendEmail.jtp?type=node&node=5880539&i=16>
> > For additional commands, e-mail: [hidden email]
> <http:///user/SendEmail.jtp?type=node&node=5880539&i=17>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> <http:///user/SendEmail.jtp?type=node&node=5880539&i=18>
> For additional commands, e-mail: [hidden email]
> <http:///user/SendEmail.jtp?type=node&node=5880539&i=19>
>
>
>
> ------------------------------
> If you reply to this email, your message will be added to the discussion
> below:
> http://maven.40175.n5.nabble.com/colored-console-tp5880214p5880539.html
> To start a new topic under Maven Developers, email
> ml-node+s40175n142166...@n5.nabble.com
> To unsubscribe from Maven Developers, click here
> <http://maven.40175.n5.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_code&node=142166&code=dGlib3JkaWdhbmFAYXBhY2hlLm9yZ3wxNDIxNjZ8LTI4OTQ5MjEwMg==>
> .
> NAML
> <http://maven.40175.n5.nabble.com/template/NamlServlet.jtp?macro=macro_viewer&id=instant_html%21nabble%3Aemail.naml&base=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespace&breadcrumbs=notify_subscribers%21nabble%3Aemail.naml-instant_emails%21nabble%3Aemail.naml-send_instant_email%21nabble%3Aemail.naml>
>


surefire1254.jpg (106K) 
<http://maven.40175.n5.nabble.com/attachment/5880964/0/surefire1254.jpg>




--
View this message in context: 
http://maven.40175.n5.nabble.com/colored-console-tp5880214p5880964.html
Sent from the Maven Developers mailing list archive at Nabble.com.

Reply via email to