Software Design by Example

The best way to learn design is to study examples [Schon1984, Petre2016], and some of the best examples of software design come from the tools programmers use in their own work. In these lessons we build small versions of things like file backup systems, testing frameworks, regular expression matchers, and browser layout engines both to demystify them and to give some insights into how experienced programmers think. We draw inspiration from [Brown2011, Brown2012, Brown2016], Mary Rose Cook's Gitlet, and the books that introduced the Unix philosophy to an entire generation of programmers [Kernighan1979, Kernighan1981, Kernighan1983, Kernighan1988].

All of the written material in this project can be freely reused under the terms of the Creative Commons - Attribution - NonCommercial license, while all of the software is made available under the terms of the Hippocratic License; see for details. All proceeds from this project will go to support the Red Door Family Shelter.

  1. Introduction
  2. Systems Programming
  3. Asynchronous Programming
  4. Unit Testing
  5. File Backup
  6. Data Tables
  7. Pattern Matching
  8. Parsing Expressions
  9. Page Templates
  10. Build Manager
  11. Layout Engine
  12. File Interpolator
  13. Module Loader
  14. Style Checker
  15. Code Generator
  16. Documentation Generator
  17. Module Bundler
  18. Package Manager
  19. Virtual Machine
  20. Debugger
  21. Conclusion
  1. License
  2. Bibliography
  3. Code of Conduct
  4. Contributing
  5. Glossary
  6. Links
  7. Authors
  8. Index