compiler. Refactored and tested cli, fixed #254.