Hacker News new | ask | show | jobs
by tlrobinson 3222 days ago
Would it be possible to write a "confirm" tool that writes stdin to stderr then waits for the user to press enter before writing to stdout?

    curl ... | confirm | apt-key ...
Of course there's no such thing as a stderr input stream, so I'm not sure this would even be possible.
2 comments

Yes, but the proper thing to do is never curl to your terminal, especially a privileged terminal. And really, you shouldn't paste either.
That would only help if it were possible for a user to visually identify if a stream is not malicious.