Fixed an assert message.
Use more than one space.
Strip _all_ trailing whitespace.
Combined the two lines.
Use preexec_functions, which will execute in non-interactive mode.