-
Notifications
You must be signed in to change notification settings - Fork 66
/
Copy pathsetup.py
59 lines (52 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
"""A setuptools based setup module
"""
import re
import setuptools
START_TAG = r"^\s*\<\!--.*exclude\s+package.*--\>\s*$"
END_TAG = r"^\s*\<\!--.*end\s+exclude\s+package.*--\>\s*$"
with open("README.md", "r") as fh:
# exclude lines from readme that dont apply to publication in package
# for example navigation bar in Readme refers to github relative paths
long_description = fh.read()
modified_description_lines = []
marked = False
for line in long_description.split("\n"):
if re.match(START_TAG, line) or re.match(END_TAG, line):
marked = True
if not marked:
modified_description_lines.append(line)
if re.match(END_TAG, line):
marked = False
long_description = "\n".join(modified_description_lines)
package_long_description = """###Databricks Labs Spark Data Generator###
The Databricks Labs Data Generator can generate realistic synthetic data sets at scale for testing,
benchmarking, environment validation and other purposes.
"""
setuptools.setup(
name="dbldatagen",
version="0.4.0post2",
author="Ronan Stokes, Databricks",
description="Databricks Labs - PySpark Synthetic Data Generator",
long_description=long_description,
long_description_content_type="text/markdown",
url="https://github.com/databrickslabs/data-generator",
project_urls={
"Databricks Labs": "https://www.databricks.com/learn/labs",
"Documentation": "https://databrickslabs.github.io/dbldatagen/public_docs/index.html"
},
# order of package declarations is important so do not re-order
packages=['dbldatagen',
'dbldatagen.distributions',
'dbldatagen.constraints',
'dbldatagen.datasets'
],
license="Databricks License",
classifiers=[
"Programming Language :: Python :: 3",
"Operating System :: OS Independent",
"Topic :: Software Development :: Testing",
"Intended Audience :: Developers",
"Intended Audience :: System Administrators"
],
python_requires='>=3.8.10',
)