Move option parsing from CLI to a new class Options.

Refactoring of the biggest class, `CLI`.