shell: reorganize shell boot process

So that we can safely import third party libraries (eg twisted)
from stoq.

That will be needed to move over a few parts from shellwindow.py
to shell, where they belong.

Change-Id: Ia7e612da59601b7e1234d963656bc086e0addccc
shell: move over termination to shell

This is not specific to a window, but rather the shell as a whole

Change-Id: Idf218495827b1a24206585b55df3ca25f8eb9348