Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[fud2] Just send Ninja's stdout to our stderr (#2065)
This solves a confusing problem where using fud2 in "stdout mode" (i.e., without `-o`) would suppress errors from the underlying commands by default (i.e., unless you *also* remember to use `-v`). We don't want Ninja printing stuff to stdout, but we also don't like hiding the error messages, so a sensible solution is to just unconditionally make Ninja's progress messages go to stderr. Seems reasonable to me, semantically: all of fud2's output other than the actual content of a "stdout mode" output should go to stderr. I also tried "buffering up" the stderr and printing it only when there's an error. This leads to marginally "cleaner" output in "stdout mode" because we don't even see Ninja's progress messages. But it also means buffering and all the various conditions get quite messy... and we also lose colors in the errors because they don't think they are talking to a terminal anymore! I think this solution is a bit simpler and better overall.
- Loading branch information