9. CLI Mini Project
TL;DR (5 lines)
- Read the core idea first.
- Understand one concept at a time.
- Run small examples.
- Fix errors early.
- Move to next chapter only when clear.
Frequent mistakes
- Skipping prerequisites.
- Reading without trying examples.
- Fixing too many errors at once.
Prerequisites: book/poche/08-essential-tests.html. See also: book/chapters/21-cli-project.html.
Goal
Assemble the basics into a concrete mini-project.
Example
Simple CLI: calc add 2 3 -> 5.
Why it matters
A short project quickly reveals areas that are still unclear.
Quick check
Which parts of the project fall under modules, types and errors?
Try this
- Read the arguments.
- Call a business procedure.
- Show result.
If you're stuck
Keep a single use case (add) before adding options.
Mini quiz
- What is the main goal of this chapter?
- Which concept is most important?
- What will you try right now?
See also
Next best action
Apply one idea from this chapter in a tiny example, then continue.