Refactor out CommandRunner