-
Notifications
You must be signed in to change notification settings - Fork 1
/
setup.py
72 lines (63 loc) · 2.45 KB
/
setup.py
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
66
67
68
69
70
71
72
#!/usr/bin/env python
# -*- coding: utf-8 -*-
"""AddC: Data-structure for online/streaming clustering.
Installation script for AddC.
"""
# Copyright (c) 2016, Carson J. Q. Farmer <carsonfarmer@gmail.com>
# Licensed under the MIT Licence (http://opensource.org/licenses/MIT).
import sys
import os
import warnings
try:
from setuptools import setup, find_packages
except ImportError:
from distutils.core import setup, find_packages
PACKAGE_NAME = "AddC"
DESCRIPTION = "AddC: Data-structure for online/streaming clustering."
MAJOR = 0
MINOR = 1
MICRO = 0
ISRELEASED = False
VERSION = '%d.%d.%d' % (MAJOR, MINOR, MICRO)
QUALIFIER = ''
FULLVERSION = VERSION
if not ISRELEASED:
FULLVERSION += '.dev'
try:
import subprocess
try:
pipe = subprocess.Popen(["git", "rev-parse", "--short", "HEAD"],
stdout=subprocess.PIPE).stdout
except OSError:
# msysgit compatibility
pipe = subprocess.Popen(
["git.cmd", "describe", "HEAD"],
stdout=subprocess.PIPE).stdout
rev = pipe.read().strip()
# Makes distutils blow up on Python 2.7
if sys.version_info[0] >= 3:
rev = rev.decode('ascii')
FULLVERSION = '%d.%d.%d.dev-%s' % (MAJOR, MINOR, MICRO, rev)
except:
warnings.warn("Couldn't get git revision")
else:
FULLVERSION += QUALIFIER
setup(name=PACKAGE_NAME, version=FULLVERSION, description=DESCRIPTION,
license='MIT', author='Carson J. Q. Farmer',
author_email='carsonfarmer@gmail.com',
keywords="streaming clustering algorithm addc kmeans online",
long_description=DESCRIPTION, packages=find_packages("."),
install_requires=["fastpair"], zip_safe=True,
setup_requires=["pytest-runner",], tests_require=["pytest",],
classifiers=["Development Status :: 2 - Pre-Alpha",
"Environment :: Console",
"Intended Audience :: Science/Research",
"Intended Audience :: Developers",
"Intended Audience :: Information Technology",
"License :: OSI Approved :: MIT License",
"Natural Language :: English",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Topic :: Scientific/Engineering :: Information Analysis",
"Topic :: System :: Distributed Computing",
])