diff --git a/.bowerrc b/.bowerrc deleted file mode 100644 index 25442973e..000000000 --- a/.bowerrc +++ /dev/null @@ -1,3 +0,0 @@ -{ - "directory": "nbclassic/static/components" -} \ No newline at end of file diff --git a/MANIFEST.in b/MANIFEST.in index 5004858d5..b01d8dfdf 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -2,6 +2,7 @@ include LICENSE # added by check-manifest include *.md +include bower-lite recursive-include docs *.md recursive-include nbclassic *.py recursive-include tests *.py diff --git a/bower-lite b/bower-lite new file mode 100644 index 000000000..eec33864a --- /dev/null +++ b/bower-lite @@ -0,0 +1,37 @@ +#!/usr/bin/env python3 +# Copyright (c) Jupyter Development Team. +# Distributed under the terms of the Modified BSD License. +""" +bower-lite +Since Bower's on its way out, +stage frontend dependencies from node_modules into components +""" +import json +import os +import shutil +from os.path import join + +HERE = os.path.abspath(os.path.dirname(__file__)) + + +components = join(HERE, "nbclassic", "static", "components") +node_modules = join(HERE, "node_modules") + +if os.path.exists(components): + shutil.rmtree(components) +os.mkdir(components) + +with open(join(HERE, "package.json")) as f: + package_json = json.load(f) + +renames = { + "jquery-ui-dist": "jquery-ui", +} + +dependencies = package_json["dependencies"] +for dep in dependencies: + src = join(node_modules, dep) + dest_name = renames.get(dep, dep) + dest = join(components, dest_name) + print(f"{src} -> {dest}") + shutil.copytree(src, dest) \ No newline at end of file diff --git a/bower.json b/bower.json deleted file mode 100644 index 5f72f6ff0..000000000 --- a/bower.json +++ /dev/null @@ -1,30 +0,0 @@ -{ - "name": "jupyter-notebook-deps", - "version": "0.0.1", - "dependencies": { - "backbone": "components/backbone#~1.2", - "bootstrap": "bootstrap#~3.4", - "bootstrap-tour": "0.9.0", - "codemirror": "components/codemirror#5.56.0+components1", - "create-react-class": "https://cdn.jsdelivr.net/npm/create-react-class@15.6.3/create-react-class.min.js", - "es6-promise": "~1.0", - "font-awesome": "components/font-awesome#~4.7.0", - "google-caja": "5669", - "jed": "~1.1.1", - "jquery": "components/jquery#~3.5.0", - "jquery-typeahead": "~2.10.6", - "jquery-ui": "components/jqueryui#~1.12", - "marked": "~0.7", - "MathJax": "^2.7.4", - "moment": "~2.19.3", - "react": "~16.0.0", - "requirejs": "~2.2", - "requirejs-text": "~2.0.15", - "requirejs-plugins": "~1.0.3", - "text-encoding": "~0.1", - "underscore": "components/underscore#~1.8.3", - "xterm.js": "https://unpkg.com/xterm@~3.1.0/dist/xterm.js", - "xterm.js-css": "https://unpkg.com/xterm@~3.1.0/dist/xterm.css", - "xterm.js-fit": "https://unpkg.com/xterm@~3.1.0/dist/addons/fit/fit.js" - } -} diff --git a/docs/environment.yml b/docs/environment.yml index 55cea9b26..cb88eae3f 100644 --- a/docs/environment.yml +++ b/docs/environment.yml @@ -1,4 +1,4 @@ -name: notebook_docs +name: nbclassic_docs channels: - conda-forge dependencies: @@ -19,3 +19,5 @@ dependencies: - prometheus_client - sphinxcontrib_github_alt - ipython_genutils + - jupyter_server>=1.8 + - notebook_shim>=0.1.0 diff --git a/nbclassic/__version__.py b/nbclassic/__version__.py deleted file mode 100644 index 8879c6c77..000000000 --- a/nbclassic/__version__.py +++ /dev/null @@ -1 +0,0 @@ -__version__ = "0.3.7" diff --git a/nbclassic/templates/page.html b/nbclassic/templates/page.html index 223731903..791d5950b 100644 --- a/nbclassic/templates/page.html +++ b/nbclassic/templates/page.html @@ -7,7 +7,7 @@ {% block title %}Jupyter Notebook{% endblock %} {% block favicon %}{% endblock %} - + @@ -15,10 +15,10 @@ {% endblock %} - - - - + + + +