Refactor Terminal Connection <-> Shell to allow multiple commands at once.