In the Designing scripts for composition recipe, we examined three aspects of an application:
- Gathering input
- Producing output
- The essential processing that connects input and output
There are several different kinds of output that applications produce:
- The principle output that helps a user make a decision or take action
- Control information that confirms that the program worked completely and correctly
- Audit summaries that are used to track the history of state changes in persistent databases
- Any error messages that indicate why the application didn't work
It's less than optimal to lump all of these various aspects into print() requests that write to standard output. Indeed, it can lead to confusion because too many different outputs are conflated into a single stream.
The OS provides two output files, standard output and...