From f191b86573c3174f210fa812a7a935059896458e Mon Sep 17 00:00:00 2001 From: Ethan Dalool Date: Sun, 4 Aug 2019 00:13:27 -0700 Subject: [PATCH] Add setup.py. --- README.md | 35 +++++++++++++++++++++++++++++++++++ pypi_upload.bat | 3 +++ setup.py | 14 ++++++++++++++ 3 files changed, 52 insertions(+) create mode 100644 pypi_upload.bat create mode 100644 setup.py diff --git a/README.md b/README.md index 7753c33..0813ab9 100644 --- a/README.md +++ b/README.md @@ -38,3 +38,38 @@ For advanced inter-file operations and better validation, I suggest using this l # What not to expect I do not intend to implement an object model for book metadata, beyond perhaps some basic getters and setters. You have full control over the `Epub.opf` BeautifulSoup object so you can edit the metadata however you want. + +--- + +``` +BSD 3-Clause License + +Copyright (c) 2019, Ethan Dalool +https://github.com/voussoir/epubfile +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + +1. Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. + +2. Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. + +3. Neither the name of the copyright holder nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +``` diff --git a/pypi_upload.bat b/pypi_upload.bat new file mode 100644 index 0000000..bbd7e80 --- /dev/null +++ b/pypi_upload.bat @@ -0,0 +1,3 @@ +py setup.py sdist +twine upload -r pypi dist\* +rmdir /s /q dist epubfile.egg-info diff --git a/setup.py b/setup.py new file mode 100644 index 0000000..ec9c24c --- /dev/null +++ b/setup.py @@ -0,0 +1,14 @@ +import setuptools + +setuptools.setup( + name='epubfile', + py_modules=['epubfile'], + version='0.0.1', + author='voussoir', + author_email='ethan@voussoir.net', + description='simple epub file reading and writing', + long_description=open('README.md', 'r').read(), + long_description_content_type='text/markdown', + url='https://github.com/voussoir/epubfile', + install_requires=['bs4', 'html5lib', 'tinycss2', 'voussoirkit'], +)