-
Notifications
You must be signed in to change notification settings - Fork 14
/
setup.py
69 lines (61 loc) · 1.9 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
#!/usr/bin/env python
# coding: utf-8
import os
from setuptools import setup, find_packages
from setupbase import create_cmdclass, install_npm
root = os.path.abspath(os.path.dirname(__file__))
js_path = os.path.join(root, 'js')
nb_path = os.path.join(root, 'jupyter_jsmol', 'nbextension', 'static')
lab_path = os.path.join(root, 'jupyter_jsmol', 'labextension')
data_files_spec = [
('share/jupyter/nbextensions/jupyter_jsmol', nb_path, '**'),
('share/jupyter/lab/extensions', lab_path, '*.tgz'),
('etc/jupyter/nbconfig/notebook.d', root, 'jupyter_jsmol.json')
]
cmdclass = create_cmdclass('jsdeps', data_files_spec=data_files_spec)
cmdclass['jsdeps'] = install_npm(js_path, build_cmd='build:all')
with open("README.md", "r") as fh:
long_description = fh.read()
setup_args = dict(
name='jupyter_jsmol',
description='JSmol viewer widget for Jupyter',
long_description=long_description,
long_description_content_type="text/markdown",
version='0.2.0',
author='Adam Fekete',
author_email='adam@fekete.co.uk',
url='https://github.com/fekad/jupyter-jsmol',
license='BSD',
platforms="Linux, Mac OS X, Windows",
keywords=['Jupyter', 'Widgets', 'IPython'],
classifiers=[
'Intended Audience :: Developers',
'Intended Audience :: Science/Research',
'Programming Language :: Python',
'Programming Language :: Python :: 3',
'Framework :: Jupyter',
],
cmdclass=cmdclass,
packages=find_packages(),
include_package_data=True,
python_requires='>=3.4',
install_requires=[
'ipywidgets>=7.0.0',
],
extras_require={
'test': [
'pytest>=3.6',
],
'docs': [
'mkdocs',
'mkdocs-material'
],
'examples': [
'ase',
'matplotlib',
'plotly'
],
},
)
if __name__ == '__main__':
setup(**setup_args)