code: def list_sub_commmands(self, cmd_name, cmd):
          
          ret = {}
          if isinstance(cmd, click.core.Group):
              for sub_cmd_name in cmd.commands:
                  sub_cmd = cmd.commands[sub_cmd_name]
                  sub = self.list_sub_commmands(sub_cmd_name, sub_cmd)
                  if sub:
                      if isinstance(sub, dict):
                          for n, c in sub.items():
                              ret['%s %s' % (cmd_name, n)] = c
                      else:
                          ret['%s %s' % (cmd_name, sub[0])] = sub[1]
          elif isinstance(cmd, click.core.Command):
              return (cmd.name, cmd)
          return ret
docs: Return all commands for a group