Fix startup commands being processed in reverse order