How can I implement my own basic unix shell in C?
问题 I'm a newbie to process and thread management. My Shell should understand PATH environment variable. It can be set and modified. It runs in two ways -interactive & batch mode. Shell is capable of taking more than one job like ls;ps;wc file;cal. I want to get my hands dirty on signals too. So I should handle ^K , ^c as well. I know I will have to use execs, forks and pipes but just can't get started. 回答1: All the unix shells are open-source - so a good place to start may be to read the code.