-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsetup.py
More file actions
65 lines (54 loc) · 2.23 KB
/
Copy pathsetup.py
File metadata and controls
65 lines (54 loc) · 2.23 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
# Copyright (c) 2022. VMware, Inc.
# SPDX-License-Identifier: Apache-2.0
import io
import os
from setuptools import find_packages, setup
# custom read implementation here allows me to use the VERSION file
# as a way to control the version number. Alternatively, I have used
# git tag names to control version release numbers. In this case
# I'm not presupposing an automated release pipeline.
def read(*names, **kwargs):
return io.open(
os.path.join(os.path.dirname(__file__), *names),
encoding=kwargs.get('encoding', 'utf8')
).read()
VERSION = str(read('VERSION')).strip()
packages = [item for item in find_packages(
'./*', exclude=['tests']) if not str(item).startswith('test')]
setup(
name='content-addressable',
version=VERSION,
description='content-addressable data structures',
author='Shawn Hartsock',
author_email='hartsocks@vmware.com',
packages=packages,
# we include the fixture data files in the test harness in the packages for
# source distributions
package_data={
'': ['*.yml', '*.yaml', '*.txt', '*.json'],
'tests/fixtures': ['*.*']
},
# we scoop the installer requirements into the packager's definition here
install_requires=read('requirements.txt').splitlines(),
# package classifiers for full-featured PyPi search engines help SEO for
# the package and increase its chances of getting noticed by a Linux
# Distribution maintainer, they will fork and create their own RPM and
# DEB packages for us.
classifiers=[
'Development Status :: 2 - Pre-Alpha',
'Intended Audience :: Developers',
'Programming Language :: Python :: 3',
'Topic :: Software Development :: Libraries :: Python Modules',
],
# testing suites are broken out into their own requirements file
test_suite='test',
tests_require=read('test-requirements.txt').splitlines(),
# This is a library and/or CLI tool and we specify the executable entry
# point for the packager by using this setting here to indicate what method
# it should call if installed in a linux distribution's /usr/local/bin
entry_points={
'console_scripts': [
# 'conadr = content_addressable.__main__:main',
]
},
)