Refactor CLI#parse so it does not boot Rails or require app code and is therefore safer to test.