-
Notifications
You must be signed in to change notification settings - Fork 1
/
setup.py
69 lines (52 loc) · 1.93 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
from setuptools import setup
from setuptools import Command
import setup_build_tasks
class CreateWinPackage(Command):
"""Setup command for creating the Windows package that gets deployed."""
description = 'Create a custom ZIP file containing source and additional files'
user_options = []
def initialize_options(self):
"""Override the default initialization options."""
pass
def finalize_options(self):
"""Override the default finalization options."""
pass
def run(self):
"""Override the default run method."""
tmp_build_task = setup_build_tasks.CreateWinPackageBuildTask()
tmp_build_task.execute_task()
class MakeDocs(Command):
"""Build command for creating sphinx documentation."""
description = 'Activates the .venv and runs the make.bat for building the sphinx docs.'
user_options = []
def initialize_options(self):
"""Override the default initialization options."""
pass
def finalize_options(self):
"""Override the default finalization options."""
pass
def run(self):
"""Override the default run method."""
tmp_build_task = setup_build_tasks.MakeSphinxDocs()
tmp_build_task.execute_task()
class MakeVenv(Command):
"""Build command for creating sphinx documentation."""
description = 'Export the .venv information into a deployable format.'
user_options = []
def initialize_options(self):
"""Override the default initialization options."""
pass
def finalize_options(self):
"""Override the default finalization options."""
pass
def run(self):
"""Override the default run method."""
tmp_build_task = setup_build_tasks.MakeVenvForDeployment()
tmp_build_task.execute_task()
setup(
cmdclass={
'create_win_package': CreateWinPackage,
'make_docs': MakeDocs,
'make_venv': MakeVenv,
},
)