From 43178ad93168ac6a2b37804e5b5e05fead8e5c80 Mon Sep 17 00:00:00 2001 From: OMOTO Kenji Date: Mon, 7 Oct 2019 13:30:59 +0900 Subject: [PATCH 1/2] Moved configurations from setup.py to setup.cfg --- setup.cfg | 38 ++++++++++++++++++++++++++++++++++++++ setup.py | 34 +--------------------------------- 2 files changed, 39 insertions(+), 33 deletions(-) diff --git a/setup.cfg b/setup.cfg index 79bc678..33ac454 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,3 +1,41 @@ + +[metadata] +name = pptx-template +version = attr: pptx_template.__version__ +description = 'The PowerPoint presentation builder using template.pptx and data(json and csv)', +long_description = file: README.rst +url = http://github.com/m3dev/pptx-template +author = Reki Murakami +author_email = reki2000@gmail.com +license = Apache-2.0 +classifiers = + Development Status :: 3 - Alpha + Topic :: Utilities + Programming Language :: Python :: 2 + Programming Language :: Python :: 2.7 + Programming Language :: Python :: 3 + Programming Language :: Python :: 3.5 + License :: OSI Approved :: Apache Software License + Operating System :: OS Independent + +keywords = + powerpoint + ppt + pptx + +[options] +test_suite = test +packages = + pptx_template +install_requires = + python-pptx==0.6.6 + pandas >=0.22,<=0.24.0 + openpyxl>=2.4.7 + +[entry_points] +console_scripts = + pptx_template = pptx_template.cli:main + [bdist_wheel] # This flag says that the code is written to work on both Python 2 and Python # 3. If at all possible, it is good practice to do this. If you cannot, you diff --git a/setup.py b/setup.py index f1a7b02..8bf1ba9 100644 --- a/setup.py +++ b/setup.py @@ -1,34 +1,2 @@ from setuptools import setup -import io -import re - -with io.open("pptx_template/__init__.py") as ver: - metadata = dict(re.findall("__([a-z]+)__\s*=\s*'([^']+)'", ver.read())) - -with io.open('README.rst', encoding='ascii') as fp: - long_description = fp.read() - -setup(name='pptx-template', - version=metadata['version'], - description='The PowerPoint presentation builder using template.pptx and data(json and csv)', - long_description=long_description, - url='http://github.com/m3dev/pptx-template', - author='Reki Murakami', - author_email='reki2000@gmail.com', - license='Apache-2.0', - packages=['pptx_template'], - test_suite='test', - install_requires=['python-pptx==0.6.6', 'pandas >=0.22,<=0.24.0', 'openpyxl>=2.4.7'], - keywords=['powerpoint', 'ppt', 'pptx'], - entry_points={ "console_scripts": [ "pptx_template=pptx_template.cli:main"]}, - classifiers=[ - "Development Status :: 3 - Alpha", - "Topic :: Utilities", - "Programming Language :: Python :: 2", - "Programming Language :: Python :: 2.7", - "Programming Language :: Python :: 3", - "Programming Language :: Python :: 3.5", - "License :: OSI Approved :: Apache Software License", - "Operating System :: OS Independent" - ] -) +setup() From ac59c5fcbd1e37978f9ec40bab9a484aa12c90bb Mon Sep 17 00:00:00 2001 From: OMOTO Kenji Date: Mon, 7 Oct 2019 13:31:38 +0900 Subject: [PATCH 2/2] Use README.md for long_description of package --- README.ja.md | 2 ++ README.md | 2 ++ README.rst | 1 - setup.cfg | 3 ++- 4 files changed, 6 insertions(+), 2 deletions(-) diff --git a/README.ja.md b/README.ja.md index 6bfe20f..09bcf4b 100644 --- a/README.ja.md +++ b/README.ja.md @@ -10,6 +10,8 @@ pptx-template は pptx のテンプレートを元に、別途用意した JSON - python 3, pandas, pptx に依存しています - 扱う json や csv の 文字コードは utf-8 前提です +詳細はこちらを参照してください: GitHub: https://github.com/m3dev/pptx-template + ### Text substitution diff --git a/README.md b/README.md index 5c6e647..c71e6d8 100644 --- a/README.md +++ b/README.md @@ -12,6 +12,8 @@ This helps your routine reporting work that have many manual copy-paste from exc - requires python envirionment (3), pandas, python-pptx - for now, only UTF-8 encoding is supported for json, csv +For further information, please visit GitHub: https://github.com/m3dev/pptx-template + ### Text substitution diff --git a/README.rst b/README.rst index cfd2384..d33ad57 100644 --- a/README.rst +++ b/README.rst @@ -12,7 +12,6 @@ This helps your routine reporting work that have many manual copy-paste from exc - requires python envirionment (2 or 3), pandas, python-pptx - for now, only UTF-8 encoding is supported for json, csv -For further information, please visit GitHub: https://github.com/m3dev/pptx-template changelogs ========== diff --git a/setup.cfg b/setup.cfg index 33ac454..1ea6c0e 100644 --- a/setup.cfg +++ b/setup.cfg @@ -3,7 +3,8 @@ name = pptx-template version = attr: pptx_template.__version__ description = 'The PowerPoint presentation builder using template.pptx and data(json and csv)', -long_description = file: README.rst +long_description = file: README.md +long_description_content_type = text/markdown url = http://github.com/m3dev/pptx-template author = Reki Murakami author_email = reki2000@gmail.com