Added comments and functions to design.txt

I added a comment under main and added the other two required things to
functions. I saw that there is already some forking happening, but I
think they should be moved to the functions. They aren't necessary for
the shell to do basic things.