forked from databrickslabs/jupyterlab-integration
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsetup.py
62 lines (53 loc) · 1.69 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
import os
import platform
import re
from setuptools import setup, find_packages
def read(fname):
return open(os.path.join(os.path.dirname(__file__), fname)).read()
def notebook_version():
with open("env.yml", "r") as fd:
env = fd.read()
r = re.compile("notebook==.*\n")
nb = r.search(env).group().strip().split("==")[1]
return nb
EXTRAS_REQUIRE = {}
INSTALL_REQUIRES = []
# Do not install on the Databricks cluster
if os.environ.get("DB_HOME") is None:
INSTALL_REQUIRES = [
"notebook==%s" % notebook_version(),
"version_parser",
"questionary",
"ssh_config==0.0.14",
"databricks_cli",
]
EXTRAS_REQUIRE = {"dev": ["pytest", "jupyter-console", "pyyaml"]}
setup(
name="databrickslabs_jupyterlab",
version="2.0.0",
author="Bernhard Walter",
author_email="[email protected]",
url="https://github.com/databrickslabs/Jupyterlab-Integration",
description=("Remote JupyterLab kernel for Databricks"),
long_description_content_type="text/markdown",
license="Databricks License",
keywords="databricks jupyter jupyterlab spark",
packages=find_packages(),
scripts=["databrickslabs-jupyterlab", "dj", "dj.bat"],
install_requires=INSTALL_REQUIRES,
extras_require=EXTRAS_REQUIRE,
data_files=[
(
"etc/jupyter/jupyter_notebook_config.d",
["databrickslabs_jupyterlab/status/etc/serverextension.json"],
),
],
include_package_data=True,
long_description=read("PYPI.md"),
classifiers=[
"Development Status :: 4 - Beta",
"Topic :: Utilities",
"License :: Other/Proprietary License",
],
zip_safe=False,
)