Updates to shell reference doc

This is quite a long document, and various bits of it haven't been updated in quite a while. I cleaned up most of the obvious flaws.