-
Notifications
You must be signed in to change notification settings - Fork 6
/
setup.py
48 lines (41 loc) · 1.46 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
import setuptools
from setuptools.command.install import install
import os
import sys
VERSION = '0.0.6.2'
with open("README.md", "r") as f:
long_description = f.read()
class VerifyVersion(install):
"""
Custom command to verify the package version matches the git tag version
"""
description = "Command ran to check if the new uploaded version matches the git tag"
def run(self):
tag = os.getenv('CIRCLE_TAG')
if tag != VERSION:
info = f'Tag {tag} does not match current version {VERSION} in setup.py'
sys.exit(info)
setuptools.setup(
name="twitter-sentiment",
version=VERSION,
author="Teddy Crepineau",
author_email="[email protected]",
description="Twitter sentiment is a Python library leveraging NLP "
"and the Twitter API to determine the emotion of a tweet",
long_description=long_description,
long_description_content_type="text/markdown",
url="https://github.com/TeddyCr/twitter-sentiment",
packages=setuptools.find_packages(),
classifiers=[
"Programming Language :: Python :: 3.6",
"License :: OSI Approved :: MIT License",
"Operating System :: MacOS",
"Development Status :: 4 - Beta",
"Programming Language :: Python :: 3.6",
"Intended Audience :: Other Audience",
"Topic :: Scientific/Engineering :: Artificial Intelligence"
],
cmdclass= {
'verify': VerifyVersion,
}
)