01 // PROJECT AT A GLANCE
42SH
CThe final shell: history, completion, aliases, scripting — a real terminal, as a team.
The project closing the first year on the system side: taking the two previous shells and bringing them up to the level of a tool you can genuinely use. History navigable with the arrow keys, aliases loaded from a configuration file, wildcards on file names, nested command execution between backticks, conditional chaining. It is the largest group project of the year, and the one where architecture decides everything: whatever was not planned upfront ends up never being done.
An advanced team shell: raw-mode line editing through termios and termcap, navigable history, aliases loaded from a .42shrc, globbing, inhibitors, backticks, parentheses and && / || operators grafted onto the minishell2 command tree.
03 // KEY OUTCOMES
- Line editing hand-written in raw terminal mode, without readline
- Completion by longest common prefix search, persistent history recallable by pattern
- Four to five contributors on the same codebase: the internal interfaces had to hold before the code could move
BEYOND THE BRIEF
- Full globbing, including inhibitors (inhibitors.c)
- Backticks with their own mini string-manipulation library (sources/backticks/)
- Line editing written by hand rather than readline
- Sixteen Criterion test files
04 // SOURCE TREE
READING SOURCE…