-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy pathbuild.py
More file actions
65 lines (59 loc) · 1.89 KB
/
build.py
File metadata and controls
65 lines (59 loc) · 1.89 KB
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
from __future__ import print_function
from setuptools import setup, find_packages
import datetime
now = datetime.datetime.now()
gradle_properties = {}
with open('gradle.properties') as fp:
for line in fp:
if '=' in line:
name, value = line.replace('\n', '').split('=', 1)
if "SNAPSHOT" in value:
dev_version = "." + now.strftime("%y%m%d%H%M") + "dev"
# dev_version = "." + now.strftime("%y%m%d%H%M")
value = value.replace("-SNAPSHOT", dev_version)
gradle_properties[name] = value
with open('VERSION', 'w') as version_file:
version_file.write(gradle_properties.get('version', '0.0.0'))
with open('VERSION', 'r') as version_file:
version_content = version_file.read().strip()
with open("README.md", "r") as fh:
try:
long_description = fh.read()
except (OSError, IOError):
long_description = "Not available"
setup(
name='proactive',
version=version_content,
description='ProActive scheduler client module',
long_description=long_description,
long_description_content_type="text/markdown",
author='Activeeon',
author_email='contact@activeeon.com',
url='https://github.com/ow2-proactive/proactive-python-client',
license='Apache-2.0',
test_suite='pytest',
tests_require=[
'mock',
'coverage',
'coveralls',
'pytest',
'python-dateutil',
'py4j',
'cloudpickle',
'codecs'
],
packages=find_packages(exclude=('tests', 'docs')),
install_requires=[
'requests',
'py4j',
'cloudpickle',
'typer',
'python-dotenv',
'wheel',
'setuptools'
],
package_dir={'proactive': 'proactive'},
package_data={'proactive': ['java/lib/*.jar', 'java/log4j.properties', 'logging.conf', '../VERSION']},
python_requires='>=2.7',
zip_safe=False
)