A small Unix-style shell written in C for Linux. The shell implements command parsing, process creation, foreground/background execution, signal handling, built-in commands, and circular-buffer command history.
- Reads user input using
read() - Executes programs using
fork(),execvp(), andwaitpid() - Supports foreground process execution
- Supports background execution using
& - Handles
SIGINTso Ctrl-C does not kill the shell itself - Reaps completed background processes with
waitpid(..., WNOHANG) - Supports built-in commands:
cdexithistory
- Implements circular-buffer command history
- Supports command recall:
rrecalls the most recent commandr xrecalls the most recent command starting withx
make
./build/minishell
make test
make clean
C, Linux, POSIX, process management, signals, Make, Git