Refactor --version command