Stdout and stderr to dev null




















The best answers are voted up and rise to the top. Stack Overflow for Teams — Collaborate and share knowledge with a private group. Create a free Team What is Teams? Learn more.

Asked 8 years, 6 months ago. Active 3 years ago. Viewed k times. What I've tried: if ls. I can only redirect one of the outputs, not both at the same time. In my edit comment I incorrectly referenced stdin instead of stdout though the edit itself is still correct.

I could not see how to fix edit comment or comment on edit review so mentioning here. Thanks — Manohar Reddy Poreddy. ManoharReddyPoreddy To output both to terminal and a file, use the tee command. How about this:. Zaar Hai Zaar Hai 7, 7 7 gold badges 33 33 silver badges 42 42 bronze badges. Charlie Martin Charlie Martin k 23 23 gold badges silver badges bronze badges. The Overflow Blog.

Stack Gives Back Safety in numbers: crowdsourcing data on nefarious IP addresses. Featured on Meta. Thank you, but this also does not work :S find. Sign up or log in Sign up using Google. Sign up using Facebook. Sign up using Email and Password. Post as a guest Name. Email Required, but never shown. The Overflow Blog. Stack Gives Back Safety in numbers: crowdsourcing data on nefarious IP addresses.

Featured on Meta. New post summary designs on greatest hits now, everywhere else eventually. Instead of suppressing errors, this might work:. Add a comment. Active Oldest Votes. Improve this answer. A cleaner solution that I commonly use is something like this: find. BlackLight BlackLight 7 7 bronze badges. Sign up or log in Sign up using Google. Sign up using Facebook. Sign up using Email and Password. Post as a guest Name.



0コメント

  • 1000 / 1000