-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathsetup.py
47 lines (43 loc) · 1.59 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
import setuptools
from setuptools.command.install import install
with open("README.md", "r", encoding="utf-8") as fh:
long_description = fh.read()
exec(open('src/securespacy/version.py').read())
class PostInstallCommand(install):
"""Post-installation for installation mode."""
def run(self):
import os
install.run(self)
pickle_fn = os.path.expanduser('~/.tokenized_matcher.pickle')
if os.path.exists(pickle_fn):
print(f'Deleting cache file {pickle_fn}. It will be regenerated.')
os.unlink(pickle_fn)
setuptools.setup(
name="securespacy",
version=__version__,
author="Joey Costoya",
author_email="[email protected]",
description="Custom Spacy tokenizer and NER extractor for IoCs",
license="Apache Software License 2.0",
long_description=long_description,
long_description_content_type="text/markdown",
url="https://github.trendmicro.com/CoreTech-FTR/securespacy",
project_urls={
"Bug Tracker": "https://github.trendmicro.com/CoreTech-FTR/securespacy/issues",
},
classifiers=[
"Programming Language :: Python :: 3",
"License :: OSI Approved :: Apache Software License",
"Operating System :: OS Independent",
],
package_dir={"": "src"},
packages=setuptools.find_packages(where="src"),
test_suite='nose.collector',
tests_require=['nose', 'publicsuffix2'],
python_requires=">=3.6",
install_requires=["spacy>=3.0.5", "publicsuffix2>=2.20191221"],
include_package_data=True,
cmdclass={
'install': PostInstallCommand,
},
)