Reorganize subcommand specifications
Reorder some other functions