forked from Anamari-ctrl/orange3-pumice
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathsetup.py
73 lines (62 loc) · 2.07 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
73
import os
from setuptools import setup, find_packages
from setuptools.command.install import install
VERSION = "1.0"
INSTALL_REQUIRES = (
'Orange3>=3.37',
'orange3-network',
'orange3-imageanalytics',
"orange-canvas-core >=0.2.2",
"orange-widget-base >=4.23.0",
),
EXTRAS_REQUIRE = {
'doc': ['sphinx', 'recommonmark', 'sphinx_rtd_theme'],
'test': ['coverage'],
}
SETUP_REQUIRES = [
'trubar>=0.3.3',
]
LONG_DESCRIPTION = open(os.path.join(os.path.dirname(__file__), 'README.pypi')).read()
ENTRY_POINTS = {
'orange3.addon': ('pumice = orangecontrib.pumice', ),
"orange.widgets": ("Pumice = orangecontrib.pumice.widgets", ),
"orange.canvas.help": (
'html-index = orangecontrib.prototypes.widgets:WIDGET_HELP_PATH'),
}
class InstallMultilingualCommand(install):
def run(self):
install.run(self)
self.compile_to_multilingual()
def compile_to_multilingual(self):
from trubar import translate
package_dir = os.path.dirname(os.path.abspath(__file__))
translate(
"msgs.jaml",
source_dir=os.path.join(self.install_lib, "orangecontrib", "pumice"),
config_file=os.path.join(package_dir, "i18n", "trubar-config.yaml"))
setup(
name="Orange3-Pumice",
description="Educational widgets for project Pumice",
license="BSD",
version=VERSION,
author='Bioinformatics Laboratory, FRI UL',
author_email='[email protected]',
url='https://github.com/biolab/orange3-pumice',
keywords=(
'orange3 add-on',
),
long_description=LONG_DESCRIPTION,
long_description_content_type='text/markdown',
packages=find_packages(),
package_data={"orangecontrib.pumice.widgets": ["icons/*.svg"]},
entry_points=ENTRY_POINTS,
install_requires=INSTALL_REQUIRES,
setup_requires=SETUP_REQUIRES,
cmdclass={
'install': InstallMultilingualCommand,
},
extras_require=EXTRAS_REQUIRE,
namespace_packages=['orangecontrib'],
include_package_data=True,
test_suite="orangecontrib.prototypes.tests.suite"
)