From 8902955fed88defde3ac211bec2dfe1827acb852 Mon Sep 17 00:00:00 2001 From: "55448286+taizan-hokuto@users.noreply.github.com" Date: Sun, 3 Nov 2019 15:02:22 +0900 Subject: [PATCH 1/3] Update setup.py --- MANIFEST.in | 3 +++ setup.py | 21 +++++++++++++++++---- 2 files changed, 20 insertions(+), 4 deletions(-) diff --git a/MANIFEST.in b/MANIFEST.in index f9bd145..fafba2f 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -1 +1,4 @@ include requirements.txt +include requirements_test.txt + + diff --git a/setup.py b/setup.py index 52c8fd1..21e40ee 100644 --- a/setup.py +++ b/setup.py @@ -1,6 +1,6 @@ -from setuptools import setup, find_packages +from setuptools import setup, find_packages, Command from codecs import open -from os import path +from os import path, system import re package_name = "pytchat" @@ -14,7 +14,6 @@ def _test_requirements(): return [name.rstrip() for name in open(path.join(root_dir, 'requirements_test.txt')).readlines()] - 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) @@ -32,6 +31,18 @@ assert url with open('README.md', encoding='utf-8') as f: long_description = f.read() +class CleanCommand(Command): + """Custom clean command to tidy up the project root.""" + user_options = [] + def initialize_options(self): + pass + def finalize_options(self): + pass + def run(self): + #system('rm -vrf ./build ./dist ./*.pyc ./*.tgz ./*.egg-info') + system('rmdir /Q pytchat.egg-info') + + setup( name=package_name, packages=find_packages(), @@ -57,5 +68,7 @@ setup( 'License :: OSI Approved :: MIT License', ], keywords='youtube livechat asyncio', - + cmdclass={ + 'clean': CleanCommand, + } ) \ No newline at end of file From 5da28e4d896253e7c31069c3a83e58274295c8be Mon Sep 17 00:00:00 2001 From: "55448286+taizan-hokuto@users.noreply.github.com" Date: Sun, 3 Nov 2019 15:03:09 +0900 Subject: [PATCH 2/3] Update setup.py --- setup.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/setup.py b/setup.py index 21e40ee..658e501 100644 --- a/setup.py +++ b/setup.py @@ -40,7 +40,7 @@ class CleanCommand(Command): pass def run(self): #system('rm -vrf ./build ./dist ./*.pyc ./*.tgz ./*.egg-info') - system('rmdir /Q pytchat.egg-info') + system('rmdir /Q /S pytchat.egg-info') setup( From 8ef6474c9018a07f63c2a95700780094cb765328 Mon Sep 17 00:00:00 2001 From: "55448286+taizan-hokuto@users.noreply.github.com" Date: Sun, 3 Nov 2019 15:14:52 +0900 Subject: [PATCH 3/3] Increment version --- MANIFEST.in | 2 +- pytchat/__init__.py | 2 +- setup.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/MANIFEST.in b/MANIFEST.in index fafba2f..8e49e2d 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -1,4 +1,4 @@ include requirements.txt include requirements_test.txt - +exclude *.egg-info diff --git a/pytchat/__init__.py b/pytchat/__init__.py index 5cff606..58767af 100644 --- a/pytchat/__init__.py +++ b/pytchat/__init__.py @@ -2,7 +2,7 @@ pytchat is a python library for fetching youtube live chat. """ __copyright__ = 'Copyright (C) 2019 taizan-hokuto' -__version__ = '0.0.1.8' +__version__ = '0.0.1.9' __license__ = 'MIT' __author__ = 'taizan-hokuto' __author_email__ = '55448286+taizan-hokuto@users.noreply.github.com' diff --git a/setup.py b/setup.py index 658e501..487cc9c 100644 --- a/setup.py +++ b/setup.py @@ -40,7 +40,7 @@ class CleanCommand(Command): pass def run(self): #system('rm -vrf ./build ./dist ./*.pyc ./*.tgz ./*.egg-info') - system('rmdir /Q /S pytchat.egg-info') + system('rmdir /Q /S pytchat.egg-info, dist') setup(