home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #16 / NN_1992_16.iso / spool / comp / unix / shell / 3248 < prev    next >
Encoding:
Text File  |  1992-07-31  |  2.0 KB  |  49 lines

  1. Newsgroups: comp.unix.shell
  2. Path: sparky!uunet!apiary!milanj
  3. From: milanj@sematech.org (Jon Milan)
  4. Subject: Re: Where does the sugar go? (was Re: Sort problem )
  5. Message-ID: <1992Jul31.173353.8155@apiary.uucp>
  6. Sender: news@apiary.uucp
  7. Nntp-Posting-Host: chile
  8. Organization: SEMATECH Manufacturing Systems Development
  9. References: <33pmg <1992Jul31.000822.13317@convex.com> <84902@netnews.upenn.edu>
  10. Date: Fri, 31 Jul 1992 17:33:53 GMT
  11. Lines: 36
  12.  
  13. In article <84902@netnews.upenn.edu> chip@eniac.seas.upenn.edu (Charles H. Buchholtz) writes:
  14. >tchrist@convex.COM (Tom Christiansen) writes:
  15. >>
  16. >>Expected output should go out to stdout.  Exceptional output related
  17. >>to diagnostics or other error messages should go out stderr.  
  18. >
  19. >I agree, but I often wonder what to do with the output "sugar", such
  20. >as prompts or headers, which are not well suited for filtering.  It's
  21. >nice when someone is looking at the output, but takes extra effort to
  22. >remove when piped into a filter, eg
  23. >
  24. >    finger | tail +2l | [...]
  25. >    ps | (read header; echo "$header"; [...])
  26. >
  27. >So, folks, what's the verdict?  Output goes to stdout, preferably
  28. >arranged in lines and fields for easy filtering.  Error messages and
  29. >diagnostics (abnormal stuff) goes to stderr.  Where should the sugar
  30. >go?  stdout?  /dev/tty?  /dev/null?  >&3?
  31.  
  32.  
  33. It can go to stdout as long as there's a command line option to shut it off
  34. for filtering.  Or preferably, an option to turn the "sugar" ON if someone
  35. wants it.
  36.  
  37. What eats me is when there's NO such option (so I have to hack around the noise),
  38. then a new version of software comes along that breaks code cause the _noise_ changed!
  39. I, for one, don't care to rewrite code for _that_ reason.
  40.  
  41. Unfortunately, UNIX is too flexible!  It'll let any programmer do just about
  42. whatever they please!  And it also lets me rewrite stuff if I don't like it!  :-)
  43.  
  44. -- 
  45. Jon Milan         jon_milan@sematech.org      |
  46. SEMATECH Manufacturing Systems Development    |
  47. "is was as was was when was was as is" (pmk)  |
  48. = = = = = = = = = = = = = = = = = = = = = = = =
  49.