-
Notifications
You must be signed in to change notification settings - Fork 16
/
Copy pathsetup.py
72 lines (60 loc) · 1.99 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
import asyncio
from setuptools import find_packages
from setuptools import setup
from distutils.command.install import install
# from octobot_script import PROJECT_NAME, VERSION
# todo figure out how not to import octobot_script.__init__.py here
PROJECT_NAME = "OctoBot-Script"
VERSION = "0.0.22" # major.minor.revision
def _post_install():
import octobot_script.cli
asyncio.run(octobot_script.cli.install_all_tentacles(True))
class InstallWithPostInstallAction(install):
def run(self):
install.run(self)
self.execute(_post_install, (), msg="Installing OctoBot-Script tentacles")
PACKAGES = find_packages(
exclude=[
"tests",
"octobot_script.imports*",
"octobot_script.user*",
]
)
# long description from README file
with open('README.md', encoding='utf-8') as f:
DESCRIPTION = f.read()
REQUIRED = open('requirements.txt').readlines()
REQUIRES_PYTHON = '>=3.8'
setup(
name=PROJECT_NAME,
version=VERSION,
url='https://github.com/Drakkar-Software/OctoBot-Script',
license='GPL-3.0',
author='Drakkar-Software',
author_email='[email protected]',
description='Backtesting framework of the OctoBot Ecosystem',
packages=PACKAGES,
cmdclass={'install': InstallWithPostInstallAction},
long_description=DESCRIPTION,
long_description_content_type='text/markdown',
tests_require=["pytest"],
test_suite="tests",
zip_safe=False,
data_files=[],
include_package_data=True, # copy non python files on install
install_requires=REQUIRED,
python_requires=REQUIRES_PYTHON,
entry_points={
'console_scripts': [
'octobot_script = octobot_script.cli:main'
]
},
classifiers=[
'Development Status :: 5 - Production/Stable',
'Operating System :: OS Independent',
'Operating System :: MacOS :: MacOS X',
'Operating System :: Microsoft :: Windows',
'Operating System :: POSIX',
'Programming Language :: Python :: 3.10',
],
)