-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathsetup.py
47 lines (37 loc) · 1.35 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 os
import setuptools
with open('requirements.txt') as f:
install_requires = f.read().splitlines()
def select_all_folders(root):
if root is None:
raise TypeError("root folder can't be None")
return [x[0] for x in os.walk(root)]
def setup_version() -> str:
version_prefix = "0.1"
version = os.environ.get("BUILD_NUMBER") if bool(os.environ.get("TEAMCITY_VERSION")) else "SNAPSHOT"
return f"{version_prefix}.{version}"
if os.path.exists("README.md"):
with open("README.md", "r") as fh:
long_description = fh.read()
else:
long_description = ""
setuptools.setup(
name="flccpsi",
version=setup_version(),
author="Yaroslav Sokolov",
author_email="[email protected]",
description="Full Line Code generation via beam search of PSI prediction models",
long_description=long_description,
long_description_content_type="text/markdown",
install_requires=install_requires,
url="https://github.com/SokolovYaroslav/PSI-Transformer",
packages=select_all_folders("flccpsi") + select_all_folders("flccpsisrc"),
nclude_package_data=True,
classifiers=[
"Programming Language :: Python :: 3",
"License :: OSI Approved :: Apache Software License",
"Operating System :: OS Independent",
"Development Status :: 3 - Alpha",
],
python_requires=">=3.8",
)