Quit command and terminal