本文整理汇总了Python中wheel.__version__方法的典型用法代码示例。如果您正苦于以下问题:Python wheel.__version__方法的具体用法?Python wheel.__version__怎么用?Python wheel.__version__使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类wheel
的用法示例。
在下文中一共展示了wheel.__version__方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: write_wheelfile
# 需要导入模块: import wheel [as 别名]
# 或者: from wheel import __version__ [as 别名]
def write_wheelfile(
self, wheelfile_base, generator="bdist_wheel (" + wheel_version + ")"
):
from email.message import Message
msg = Message()
msg["Wheel-Version"] = "1.0" # of the spec
msg["Generator"] = generator
msg["Root-Is-Purelib"] = str(self.root_is_pure).lower()
# Doesn't work for bdist_wininst
impl_tag, abi_tag, plat_tag = self.get_tag()
for impl in impl_tag.split("."):
for abi in abi_tag.split("."):
for plat in plat_tag.split("."):
msg["Tag"] = "-".join((impl, abi, plat))
wheelfile_path = os.path.join(wheelfile_base, "WHEEL")
logger.info("creating %s", wheelfile_path)
with open(wheelfile_path, "w") as f:
Generator(f, maxheaderlen=0).flatten(msg)
示例2: write_wheelfile
# 需要导入模块: import wheel [as 别名]
# 或者: from wheel import __version__ [as 别名]
def write_wheelfile(self, wheelfile_base, generator='bdist_wheel (' + wheel.__version__ + ')'):
from email.message import Message
msg = Message()
msg['Wheel-Version'] = '1.0' # of the spec
msg['Generator'] = generator
msg['Root-Is-Purelib'] = str(self.root_is_pure).lower()
# Doesn't work for bdist_wininst
impl_tag, abi_tag, plat_tag = self.get_tag()
for impl in impl_tag.split('.'):
for abi in abi_tag.split('.'):
for plat in plat_tag.split('.'):
msg['Tag'] = '-'.join((impl, abi, plat))
wheelfile_path = os.path.join(wheelfile_base, 'WHEEL')
logger.info('creating %s', wheelfile_path)
with open(wheelfile_path, 'w') as f:
Generator(f, maxheaderlen=0).flatten(msg)
示例3: write_wheelfile
# 需要导入模块: import wheel [as 别名]
# 或者: from wheel import __version__ [as 别名]
def write_wheelfile(self, wheelfile_base, generator='bdist_wheel (' + wheel.__version__ + ')'):
from email.message import Message
msg = Message()
msg['Wheel-Version'] = '1.0' # of the spec
msg['Generator'] = generator
msg['Root-Is-Purelib'] = str(self.root_is_purelib).lower()
# Doesn't work for bdist_wininst
impl_tag, abi_tag, plat_tag = self.get_tag()
for impl in impl_tag.split('.'):
for abi in abi_tag.split('.'):
for plat in plat_tag.split('.'):
msg['Tag'] = '-'.join((impl, abi, plat))
wheelfile_path = os.path.join(wheelfile_base, 'WHEEL')
logger.info('creating %s', wheelfile_path)
with open(wheelfile_path, 'w') as f:
Generator(f, maxheaderlen=0).flatten(msg)
示例4: get_version
# 需要导入模块: import wheel [as 别名]
# 或者: from wheel import __version__ [as 别名]
def get_version(*file_paths):
"""Retrieves the version from django_json_widget/__init__.py"""
filename = os.path.join(os.path.dirname(__file__), *file_paths)
version_file = open(filename).read()
version_match = re.search(r"^__version__ = ['\"]([^'\"]*)['\"]",
version_file, re.M)
if version_match:
return version_match.group(1)
raise RuntimeError('Unable to find version string.')
# version = get_version("django_json_widget", "__init__.py")
示例5: get_version
# 需要导入模块: import wheel [as 别名]
# 或者: from wheel import __version__ [as 别名]
def get_version(*file_paths):
"""Retrieves the version from django_mptt_comments/__init__.py"""
filename = os.path.join(os.path.dirname(__file__), *file_paths)
version_file = open(filename).read()
version_match = re.search(r"^__version__ = ['\"]([^'\"]*)['\"]",
version_file, re.M)
if version_match:
return version_match.group(1)
raise RuntimeError('Unable to find version string.')
示例6: get_version
# 需要导入模块: import wheel [as 别名]
# 或者: from wheel import __version__ [as 别名]
def get_version(*file_paths):
"""Retrieves the version from longclaw/__init__.py"""
filename = os.path.join(os.path.dirname(__file__), *file_paths)
version_file = open(filename).read()
version_match = re.search(r"^__version__ = ['\"]([^'\"]*)['\"]",
version_file, re.M)
if version_match:
return version_match.group(1)
raise RuntimeError('Unable to find version string.')
示例7: get_version
# 需要导入模块: import wheel [as 别名]
# 或者: from wheel import __version__ [as 别名]
def get_version(*file_paths):
"""Retrieves the version from django_better_admin_arrayfield/__init__.py"""
filename = os.path.join(os.path.dirname(__file__), *file_paths)
version_file = open(filename).read()
version_match = re.search(r"^__version__ = ['\"]([^'\"]*)['\"]", version_file, re.M)
if version_match:
return version_match.group(1)
raise RuntimeError("Unable to find version string.")
示例8: get_version
# 需要导入模块: import wheel [as 别名]
# 或者: from wheel import __version__ [as 别名]
def get_version(*file_paths):
"""Retrieves the version from django_cookies_samesite/__init__.py"""
filename = os.path.join(os.path.dirname(__file__), *file_paths)
version_file = open(filename).read()
version_match = re.search(r"^__version__ = ['\"]([^'\"]*)['\"]",
version_file, re.M)
if version_match:
return version_match.group(1)
raise RuntimeError('Unable to find version string.')
示例9: get_version
# 需要导入模块: import wheel [as 别名]
# 或者: from wheel import __version__ [as 别名]
def get_version(*file_paths):
"""Retrieves the version from business_logic/__init__.py"""
filename = os.path.join(os.path.dirname(__file__), *file_paths)
version_file = open(filename).read()
version_match = re.search(r"^__version__ = ['\"]([^'\"]*)['\"]",
version_file, re.M)
if version_match:
return version_match.group(1)
raise RuntimeError('Unable to find version string.')
示例10: main
# 需要导入模块: import wheel [as 别名]
# 或者: from wheel import __version__ [as 别名]
def main():
try:
import pip
except ImportError:
raise EnvironmentError("pip installation is required")
try:
import wheel
except ImportError:
raise EnvironmentError("wheel installation is required")
try:
import packaging
except ImportError:
packaging_version = None
else:
packaging_version = packaging.__version__
try:
import setuptools
except ImportError:
setuptools_version = None
else:
setuptools_version = setuptools.__version__
env = default_environment()
env["python_executable"] = sys.executable
env["pip_version"] = pip.__version__
env["wheel_version"] = wheel.__version__
env["packaging_version"] = packaging_version
env["setuptools_version"] = setuptools_version
env = sorted(env.items())
result = json.dumps(env, indent=2)
print(result)
示例11: get_version
# 需要导入模块: import wheel [as 别名]
# 或者: from wheel import __version__ [as 别名]
def get_version(*file_paths):
"""Retrieves the version from wagtailmath/__init__.py"""
filename = os.path.join(os.path.dirname(__file__), *file_paths)
version_file = open(filename).read()
version_match = re.search(r"^__version__ = ['\"]([^'\"]*)['\"]",
version_file, re.M)
if version_match:
return version_match.group(1)
raise RuntimeError('Unable to find version string.')
示例12: get_version
# 需要导入模块: import wheel [as 别名]
# 或者: from wheel import __version__ [as 别名]
def get_version(*file_paths):
"""Retrieves the version from django_fine_uploader/__init__.py"""
filename = os.path.join(os.path.dirname(__file__), *file_paths)
version_file = open(filename).read()
version_match = re.search(r"^__version__ = ['\"]([^'\"]*)['\"]",
version_file, re.M)
if version_match:
return version_match.group(1)
raise RuntimeError('Unable to find version string.')
示例13: get_version
# 需要导入模块: import wheel [as 别名]
# 或者: from wheel import __version__ [as 别名]
def get_version(*file_paths):
"""Retrieves the version from django_zombodb/__init__.py"""
filename = os.path.join(os.path.dirname(__file__), *file_paths)
version_file = open(filename).read()
version_match = re.search(r"^__version__ = ['\"]([^'\"]*)['\"]",
version_file, re.M)
if version_match:
return version_match.group(1)
raise RuntimeError('Unable to find version string.')
示例14: get_version
# 需要导入模块: import wheel [as 别名]
# 或者: from wheel import __version__ [as 别名]
def get_version(*file_paths):
"""Retrieves the version from djangocms_spa/__init__.py"""
filename = os.path.join(os.path.dirname(__file__), *file_paths)
version_file = open(filename).read()
version_match = re.search(r"^__version__ = ['\"]([^'\"]*)['\"]",
version_file, re.M)
if version_match:
return version_match.group(1)
raise RuntimeError('Unable to find version string.')
示例15: get_version
# 需要导入模块: import wheel [as 别名]
# 或者: from wheel import __version__ [as 别名]
def get_version(*file_paths):
"""Retrieves the version from rest_framework_tus/__init__.py"""
filename = os.path.join(os.path.dirname(__file__), *file_paths)
version_file = open(filename).read()
version_match = re.search(r"^__version__ = ['\"]([^'\"]*)['\"]",
version_file, re.M)
if version_match:
return version_match.group(1)
raise RuntimeError('Unable to find version string.')