Skip to content
This repository has been archived by the owner on Aug 23, 2018. It is now read-only.

Print errors to stderr instead of stdout #70

Closed
rtfeldman opened this issue Nov 23, 2015 · 6 comments
Closed

Print errors to stderr instead of stdout #70

rtfeldman opened this issue Nov 23, 2015 · 6 comments

Comments

@rtfeldman
Copy link

In elm-test we generate a temporary .js file for the compiled Test.elm before running the tests.

By default that means we get output like this every time the tests run:

Successfully generated /var/folders/f2/bgdp00xs327b2qx7mmg6jkbh0000gn/T/elm_test_1151022-3235-1bxa84u.js
Successfully compiled Test.elm

This is pretty ugly, so what we've been doing is piping elm-make's stdout and discarding lines that start with "Success". This works, but introduces a new problem: because we're piping the output instead of just giving elm-make direct access to the console, we miss out on colorized error messages. (Thanks @evancz for pointing out the culprit!)

If elm-make wrote error messages to stderr and success messages to stdout, we could continue to pipe the stdout stream for filtering, but let stderr pass through as normal (colors and all), meaning everything would be rad and awesome!

@itrelease
Copy link

@rtfeldman can you provide example for your case so I can reproduce your problem?

@rtfeldman
Copy link
Author

Sure, just take a look at https://travis-ci.org/rtfeldman/node-elm-test - it currently works as described above. 😃

@itrelease
Copy link

@rtfeldman that was fast 👍 thanks

@jvoigtlaender
Copy link
Contributor

On the other hand, #32 argues that the success messages should go to stderr as well.

@rtfeldman
Copy link
Author

True, but it argues that based on an explicitly unsupported motivating use case. I commented over there.

@evancz
Copy link
Contributor

evancz commented May 12, 2016

Tracked in #98

@evancz evancz closed this as completed May 12, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants