develop.py 文件源码

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

项目:SHAREOpenRefineWkshop 作者: cmh2166 项目源码 文件源码
def _resolve_setup_path(egg_base, install_dir, egg_path):
        """
        Generate a path from egg_base back to '.' where the
        setup script resides and ensure that path points to the
        setup path from $install_dir/$egg_path.
        """
        path_to_setup = egg_base.replace(os.sep, '/').rstrip('/')
        if path_to_setup != os.curdir:
            path_to_setup = '../' * (path_to_setup.count('/') + 1)
        resolved = normalize_path(os.path.join(install_dir, egg_path, path_to_setup))
        if resolved != normalize_path(os.curdir):
            raise DistutilsOptionError(
                "Can't get a consistent path to setup script from"
                " installation directory", resolved, normalize_path(os.curdir))
        return path_to_setup
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号