you-get/setup.py

43 lines
1.2 KiB
Python
Raw Permalink Normal View History

2012-08-31 17:20:38 +02:00
#!/usr/bin/env python3
2013-02-12 22:04:39 +01:00
PROJ_NAME = 'you-get'
PACKAGE_NAME = 'you_get'
PROJ_METADATA = '%s.json' % PROJ_NAME
2012-08-31 17:20:38 +02:00
2012-12-09 17:33:24 +01:00
import os, json, imp
2012-08-31 17:20:38 +02:00
here = os.path.abspath(os.path.dirname(__file__))
proj_info = json.loads(open(os.path.join(here, PROJ_METADATA)).read())
README = open(os.path.join(here, 'README.txt')).read()
CHANGELOG = open(os.path.join(here, 'CHANGELOG.txt')).read()
2013-02-12 22:04:39 +01:00
VERSION = imp.load_source('version', os.path.join(here, 'src/%s/version.py' % PACKAGE_NAME)).__version__
2012-08-31 17:20:38 +02:00
2012-09-01 00:55:45 +02:00
from setuptools import setup, find_packages
2012-08-31 17:20:38 +02:00
setup(
name = proj_info['name'],
2012-12-09 17:33:24 +01:00
version = VERSION,
2012-08-31 17:20:38 +02:00
author = proj_info['author'],
author_email = proj_info['author_email'],
url = proj_info['url'],
license = proj_info['license'],
description = proj_info['description'],
keywords = proj_info['keywords'],
2012-09-01 00:55:45 +02:00
2012-08-31 17:20:38 +02:00
long_description = README + '\n\n' + CHANGELOG,
2013-02-12 22:04:39 +01:00
packages = find_packages('src'),
package_dir = {'' : 'src'},
test_suite = 'tests',
2012-09-01 00:55:45 +02:00
platforms = 'any',
zip_safe = False,
include_package_data = True,
classifiers = proj_info['classifiers'],
2012-08-31 17:20:38 +02:00
2012-09-01 00:55:45 +02:00
entry_points = {'console_scripts': proj_info['console_scripts']}
2012-08-31 17:20:38 +02:00
)