Tidy up the structure of the cli package, keep subcommand related functions grouped together in a package.