python-plexapi/setup.py

38 lines
973 B
Python
Raw Normal View History

2014-12-29 03:21:58 +00:00
#!/usr/bin/python
# -*- coding: utf-8 -*-
2014-12-29 03:21:58 +00:00
"""
Install PlexAPI
"""
2016-05-24 02:13:26 +00:00
import re
2014-12-29 03:21:58 +00:00
from distutils.core import setup
# Get the current version
2014-12-29 03:21:58 +00:00
with open('plexapi/__init__.py') as handle:
for line in handle.readlines():
if line.startswith('VERSION'):
version = re.findall("'([0-9\.]+?)'", line)[0]
# Get README.rst contents
readme = open('README.rst', 'r').read()
# Get requirments
requirements = []
with open('requirements.txt') as handle:
for line in handle.readlines():
if not line.startswith('#'):
package = line.strip().split('=', 1)[0]
requirements.append(package)
2014-12-29 03:21:58 +00:00
setup(
name='PlexAPI',
version=version,
2014-12-29 03:21:58 +00:00
description='Python bindings for the Plex API.',
author='Michael Shepanski',
author_email='michael.shepanski@gmail.com',
url='https://github.com/pkkid/plexapi',
packages=['plexapi'],
install_requires=requirements,
long_description=readme,
2014-12-29 03:21:58 +00:00
keywords=['plex', 'api'],
)