cordova-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CB-9784) Remove CLI logger levels prefixes
Date Tue, 13 Oct 2015 00:32:05 GMT

    [ https://issues.apache.org/jira/browse/CB-9784?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14954142#comment-14954142
] 

ASF GitHub Bot commented on CB-9784:
------------------------------------

Github user nikhilkh commented on a diff in the pull request:

    https://github.com/apache/cordova-cli/pull/224#discussion_r41816178
  
    --- Diff: src/logger.js ---
    @@ -59,13 +58,12 @@ function formatError(error, isVerbose) {
     logger.log = function (logLevel, message) {
         if (this.levels[logLevel] >= this.levels[this.logLevel]) {
             var isVerbose = this.logLevel === 'verbose';
    -        var prefix = this.prefixes[logLevel] ? this.prefixes[logLevel] + ': ' : '';
     
             if(message instanceof Error) {
                 message = formatError(message, isVerbose);
             }
     
    -        message = prefix + message + EOL;
    +        message = message + EOL;
     
             if (!this.cursor) {
                 this.output.write(message);
    --- End diff --
    
    I just realized that we should write error messages to stderr instead of output - is that
correct?


> Remove CLI logger levels prefixes
> ---------------------------------
>
>                 Key: CB-9784
>                 URL: https://issues.apache.org/jira/browse/CB-9784
>             Project: Apache Cordova
>          Issue Type: Bug
>          Components: CLI
>            Reporter: Sergey Shakhnazarov
>            Assignee: Sergey Shakhnazarov
>
> EventEmitter usage provides info on an event level so the prefixing may be superfluous
taking into account we have coloring distinction for event levels.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org


Mime
View raw message