easy_install.py 文件源码

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

项目:Flask_Blog 作者: sugarguo 项目源码 文件源码
def fix_jython_executable(executable, options):
    if sys.platform.startswith('java') and is_sh(executable):
        # Workaround for Jython is not needed on Linux systems.
        import java
        if java.lang.System.getProperty("os.name") == "Linux":
            return executable

        # Workaround Jython's sys.executable being a .sh (an invalid
        # shebang line interpreter)
        if options:
            # Can't apply the workaround, leave it broken
            log.warn(
                "WARNING: Unable to adapt shebang line for Jython,"
                " the following script is NOT executable\n"
                "         see http://bugs.jython.org/issue1112 for"
                " more information.")
        else:
            return '/usr/bin/env %s' % executable
    return executable
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号