Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save Barolina/60e3e0bcf31f490f88f87b10968178e9 to your computer and use it in GitHub Desktop.
Save Barolina/60e3e0bcf31f490f88f87b10968178e9 to your computer and use it in GitHub Desktop.
сборка ptython пакета (c рекурсивным обходом)

в файле MANIFEST.in

# Include the README
include *.md

# Include the license file
include LICENSE.txt

# Include locale files
recursive-include "наименование пакета" *.*

a файле setup.py

# coding: utf-8
import os
import setuptools
from rrd_xml_mp2docx import name as package_name, version as package_version

with open('README.md', 'r', encoding='utf-8') as fn:
    long_description = fn.read()


def read_requirements():
    reqs_path = os.path.join('.', 'requirements.txt')
    with open(reqs_path, 'r', encoding='utf-8') as f:
        requirements = [line.rstrip() for line in f]
    return requirements


setuptools.setup(
    name=package_name,
    version=package_version,
    description='Утилита',
    long_description=long_description,
    long_description_content_type='text/markdown',
    url='https://bitbucket.org/пакет.git',
    author='',
    author_email='@mail.ru',
    license='MIT',
    classifiers=[
        'Development Status :: 3 - Alpha'
        'Operating System :: OS Independent',
        'Programming Language :: Python :: 3',
        'Programming Language :: Python :: 3.4',
        'Programming Language :: Python :: 3.5',
        'Programming Language :: Python :: 3.6',
        'Programming Language :: Python :: 3.7',
    ],
    packages=setuptools.find_packages(exclude=['examples', 'tests', 'docs']),
    install_requires=read_requirements(),
    python_requires='~=3.4',
    include_package_data=True,
    entry_points={
        'console_scripts': [
            'rrd-xml-mp2docx=rrd_xml_mp2docx.__main__:main'
        ]
    }
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment