cmd.py 文件源码

python
阅读 26 收藏 0 点赞 0 评论 0

项目:apimas 作者: grnet 项目源码 文件源码
def get_command(self, ctx, name):
        config_file = ctx.params.get('config')
        try:
            conf = config.configure(path=config_file)
        except ex.ApimasException as e:
            raise click.BadOptionUsage(str(e))
        root_url, spec = conf['root'], conf['spec']
        cli = _construct_cli(root_url, spec)
        if name is None:
            return cli.get_base_command()
        return cli.endpoint_groups.get(name)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号