Nrechati/42sh-UNIX-Shell — reverse-engineered prompt
Reverse engineered prompt
Build me a Unix shell in C called 42sh that I can compile with make and run from the terminal.
I want it to feel like a real POSIX style shell, not just a toy. It should show a prompt, run commands with arguments, use PATH, handle return values, pipes, command separators, logical commands, input and output redirection, quoted strings, escaped characters, variables, export, tilde expansion, parameter expansion, and arithmetic expansion.
Please include line editing with arrows, home and end, copy and paste, multiline input, history, Ctrl R search, saved history, tab completion for commands, files, and variables, plus job control with background commands, jobs, fg, and bg. Add common built in commands like cd, echo, exit, pwd, type, set, unset, export, test, hash, and fc.
Keep it self contained, with any helper libraries needed inside the project, and include a clear README for building and using it. Look up POSIX shell behavior online if you need to.
Want more depth? Deep Reverse