9
macbury
4y

Here is a stupid fucking idea:

use console.error for displaying warnings.

I look at you react

Comments
  • 3
    That sounds like the sloppy shit I associate with react. You have fed my confirmation bias, and I am now happy. 🍪
  • 3
    Say that to GIT please !

    They output everything in std::error. At least on windows.

    It's a nightmare trying to make PS scripts work (Need to manually redefine std::error as "normal " output and restore before calling "normal" tools
  • 0
    Wrong order of proverbs make it funny,, heh.
  • 3
    @NoToJavaScript
    I mean, not really? The problem here is powershell, and windows people not understanding how a terminal works.

    Powershell builds this lovely abstraction wherein .Net code apes being a terminal, and in the process creates a system that is constantly confused about what it wants to do and baits its users into par-undebuggable corners.

    Shell scripts invoke processes then analyze result codes to determine what to do next. For some reason, the architects of PS didn't grok this and made this appear to be an edge case. They instead created magic wrappers and then just pipe-forward the result of the executable to the "session," assuming everything will have a compatible abstraction.

    tl;dr You should be decoupling your external application invocations from powershell's session construct, see attached.
  • 0
    @SortOfTested

    I do not know. If application writes to std::error it is assumed that app failed. Seems pretty good to me. Why would git write “git branch” result in std::error ?
Add Comment