Front Page /// Categories /// Site Index
Unix Philosophy
Built on the principle of lots of little tools being put together to do big jobs, this philosophy allows lots of the system to get faster every time someone improves any part of it.
Due to a very good decision right at the start, you already have standards for source code, as the entire system is designed to be source code compatible,
so that you can just compile code on a different system, and it will work with hardly any modification.
The whole system is built on a number of simple principles:
- Modularity - write simple parts connected by clean interfaces
- Clarity - being clear is better than being clever
- Composition - design your programs to be connected to other programs
- Seperation - seperate the engine from the interface, and the policy from the mechanism
- Simplicity - as Hume pointed out years ago, don't make things more complex than they need to be
- Parsimony - only write big programs when a smaller one won't do the job
- Transparency - design to make debugging and code inspection easier
- Robustness - if it is simple and transparent, it is much less likely to break
- Representation - move knowledge from the program to the data where it makes the program logic simpler
- Least Surprise - if there is already a standard way of doing the interface, don't reinvent the wheel unnecessarily
- Silence - If you don't have anything to say, then say nothing, as generations of mothers have tried to get their children to behave
- Repair - if you must have something fail, then do so, but make it fail as early and as loudly as possible
- Economy - computers have more time to do things than programmers, so don't have programmers wasting time if the computer can instead
- Generation - don't do things by hand unless you have to, especially when you can write a program to do it for you
- Optimisation - get it to work first, then polish it up
- Diversity - distrust claims of being the only way of doing things
- Extensibility - design to expand, because it is much harder to build this capability in as an afterthought
For more about this, see the book "the art of unix programming by Eric Raymond".
last modified 01:25 2006/12/17