I would like to do this:

stage {
    timestamps {
        ansiColor('xterm') {
            sh 'echo "Hello World"'
        }

    }
}

Or, using alternative syntax:


stage {
    wrap([$class: 'TimestamperBuildWrapper']) {
        wrap([$class: 'AnsiColorBuildWrapper', colorMapName: 'xterm']) {
            sh 'echo "Hello World"'
        }

    }
}


Unfortunately, the second wrapper just gets ignored, so in the above case, 
I see only timestamps, but no color.

Using the Job-DSL, this was extremely straightforward:

wrappers {
    timestamps()
    colorizeOutput()
}

How to solve this problem?

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/378ec6b1-8698-4c22-b527-1bfc20ca214a%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to