add code for subcommand support