Limit lines
This commit is contained in:
26
setup.py
26
setup.py
@@ -1,5 +1,4 @@
|
||||
from setuptools import setup, find_packages, Command
|
||||
#from codecs import open as open_c
|
||||
from os import path, system, remove, rename, removedirs
|
||||
import re
|
||||
|
||||
@@ -8,10 +7,14 @@ package_name = "pytchat"
|
||||
root_dir = path.abspath(path.dirname(__file__))
|
||||
|
||||
def _requirements():
|
||||
return [name.rstrip() for name in open(path.join(root_dir, 'requirements.txt')).readlines()]
|
||||
return [name.rstrip()
|
||||
for name in open(path.join(
|
||||
root_dir, 'requirements.txt')).readlines()]
|
||||
|
||||
def _test_requirements():
|
||||
return [name.rstrip() for name in open(path.join(root_dir, 'requirements_test.txt')).readlines()]
|
||||
return [name.rstrip()
|
||||
for name in open(path.join(
|
||||
root_dir, 'requirements_test.txt')).readlines()]
|
||||
|
||||
txt= ''
|
||||
with open('README.MD', 'r', encoding='utf-8') as f:
|
||||
@@ -25,11 +28,16 @@ rename("README1.MD","README.MD")
|
||||
|
||||
with open(path.join(root_dir, package_name, '__init__.py')) as f:
|
||||
init_text = f.read()
|
||||
version = re.search(r'__version__\s*=\s*[\'\"](.+?)[\'\"]', init_text).group(1)
|
||||
license = re.search(r'__license__\s*=\s*[\'\"](.+?)[\'\"]', init_text).group(1)
|
||||
author = re.search(r'__author__\s*=\s*[\'\"](.+?)[\'\"]', init_text).group(1)
|
||||
author_email = re.search(r'__author_email__\s*=\s*[\'\"](.+?)[\'\"]', init_text).group(1)
|
||||
url = re.search(r'__url__\s*=\s*[\'\"](.+?)[\'\"]', init_text).group(1)
|
||||
version = re.search(
|
||||
r'__version__\s*=\s*[\'\"](.+?)[\'\"]', init_text).group(1)
|
||||
license = re.search(
|
||||
r'__license__\s*=\s*[\'\"](.+?)[\'\"]', init_text).group(1)
|
||||
author = re.search(
|
||||
r'__author__\s*=\s*[\'\"](.+?)[\'\"]', init_text).group(1)
|
||||
author_email = re.search(
|
||||
r'__author_email__\s*=\s*[\'\"](.+?)[\'\"]', init_text).group(1)
|
||||
url = re.search(
|
||||
r'__url__\s*=\s*[\'\"](.+?)[\'\"]', init_text).group(1)
|
||||
|
||||
assert version
|
||||
assert license
|
||||
@@ -56,7 +64,6 @@ setup(
|
||||
long_description_content_type='text/markdown',
|
||||
license=license,
|
||||
install_requires=_requirements(),
|
||||
#tests_require=_test_requirements(),
|
||||
description="a python library for fetching youtube live chat.",
|
||||
classifiers=[
|
||||
'Natural Language :: Japanese',
|
||||
@@ -67,6 +74,7 @@ setup(
|
||||
'Programming Language :: Python :: 3.5',
|
||||
'Programming Language :: Python :: 3.6',
|
||||
'Programming Language :: Python :: 3.7',
|
||||
'Programming Language :: Python :: 3.8',
|
||||
'License :: OSI Approved :: MIT License',
|
||||
],
|
||||
keywords='youtube livechat asyncio',
|
||||
|
||||
Reference in New Issue
Block a user