本文整理汇总了Python中setuptools.command.easy_install.easy_install.install_egg_scripts方法的典型用法代码示例。如果您正苦于以下问题:Python easy_install.install_egg_scripts方法的具体用法?Python easy_install.install_egg_scripts怎么用?Python easy_install.install_egg_scripts使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类setuptools.command.easy_install.easy_install
的用法示例。
在下文中一共展示了easy_install.install_egg_scripts方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: install_egg_scripts
# 需要导入模块: from setuptools.command.easy_install import easy_install [as 别名]
# 或者: from setuptools.command.easy_install.easy_install import install_egg_scripts [as 别名]
def install_egg_scripts(self, dist):
if dist is not self.dist:
# Installing a dependency, so fall back to normal behavior
return easy_install.install_egg_scripts(self, dist)
# create wrapper scripts in the script dir, pointing to dist.scripts
# new-style...
self.install_wrapper_scripts(dist)
# ...and old-style
for script_name in self.distribution.scripts or []:
script_path = os.path.abspath(convert_path(script_name))
script_name = os.path.basename(script_path)
with io.open(script_path) as strm:
script_text = strm.read()
self.install_script(dist, script_name, script_text, script_path)
示例2: install_egg_scripts
# 需要导入模块: from setuptools.command.easy_install import easy_install [as 别名]
# 或者: from setuptools.command.easy_install.easy_install import install_egg_scripts [as 别名]
def install_egg_scripts(self, dist):
if dist is not self.dist:
# Installing a dependency, so fall back to normal behavior
return easy_install.install_egg_scripts(self,dist)
# create wrapper scripts in the script dir, pointing to dist.scripts
# new-style...
self.install_wrapper_scripts(dist)
# ...and old-style
for script_name in self.distribution.scripts or []:
script_path = os.path.abspath(convert_path(script_name))
script_name = os.path.basename(script_path)
f = open(script_path,'rU')
script_text = f.read()
f.close()
self.install_script(dist, script_name, script_text, script_path)
示例3: install_egg_scripts
# 需要导入模块: from setuptools.command.easy_install import easy_install [as 别名]
# 或者: from setuptools.command.easy_install.easy_install import install_egg_scripts [as 别名]
def install_egg_scripts(self, dist):
if dist is not self.dist:
# Installing a dependency, so fall back to normal behavior
return easy_install.install_egg_scripts(self, dist)
# create wrapper scripts in the script dir, pointing to dist.scripts
# new-style...
self.install_wrapper_scripts(dist)
# ...and old-style
for script_name in self.distribution.scripts or []:
script_path = os.path.abspath(convert_path(script_name))
script_name = os.path.basename(script_path)
f = open(script_path, 'rU')
script_text = f.read()
f.close()
self.install_script(dist, script_name, script_text, script_path)