Skip to content

Jupyterlab binder update #157

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 12 commits into from
Jan 28, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

## Save, reuse, and share code snippets using JupyterLab Code Snippets

![Github Actions Status](https://github.com/jupytercalpoly/jupyterlab-code-snippets/workflows/Build/badge.svg) [![Binder](https://mybinder.org/badge_logo.svg)](https://mybinder.org/v2/gh/jupytercalpoly/jupyterlab-code-snippets.git/master?urlpath=lab) [![NPM Version](https://img.shields.io/npm/v/jupyterlab-code-snippets.svg?style=flat)](https://npmjs.org/package/jupyterlab-code-snippets 'View this project on npm') [![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://github.com/jupytercalpoly/jupyterlab-code-snippets/blob/master/LICENSE) [![Documentation Status](https://readthedocs.org/projects/jupyterlab-code-snippets-documentation/badge/?version=latest)](https://jupyterlab-code-snippets-documentation.readthedocs.io/en/latest/?badge=latest)
![Github Actions Status](https://github.com/jupytercalpoly/jupyterlab-code-snippets/workflows/Build/badge.svg) [![Binder](https://mybinder.org/badge_logo.svg)](https://mybinder.org/v2/gh/jahn96/jupyterlab-code-snippets.git/jupyterlab_update?urlpath=lab) [![NPM Version](https://img.shields.io/npm/v/jupyterlab-code-snippets.svg?style=flat)](https://npmjs.org/package/jupyterlab-code-snippets 'View this project on npm') [![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://github.com/jupytercalpoly/jupyterlab-code-snippets/blob/master/LICENSE) [![Documentation Status](https://readthedocs.org/projects/jupyterlab-code-snippets-documentation/badge/?version=latest)](https://jupyterlab-code-snippets-documentation.readthedocs.io/en/latest/?badge=latest)

This extension is a derivative of [Elyra](https://github.com/elyra-ai/elyra)'s original design and further developed by Jupyter Cal Poly Team.

Expand Down
33 changes: 28 additions & 5 deletions binder/postBuild
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@ from pathlib import Path

ROOT = Path.cwd()

print("Current Working dir:", ROOT)

def _(*args, **kwargs):
""" Run a command, echoing the args

Expand All @@ -27,20 +29,41 @@ def _(*args, **kwargs):
sys.exit(return_code)

# verify the environment is self-consistent before even starting
_(sys.executable, "-m", "pip", "check")
# _(sys.executable, "-m", "pip", "check")

# install the labextension
_(sys.executable, "-m", "pip", "install", "-e", ".")

# verify the environment the extension didn't break anything
_(sys.executable, "-m", "pip", "check")
# _(sys.executable, "-m", "pip", "check")

# list the extensions
_("jupyter", "server", "extension", "list")
# _("jupyter", "server", "extension", "list")

# initially list installed extensions to determine if there are any surprises
_("jupyter", "labextension", "list")

# _("jupyter", "labextension", "list")

print("JupyterLab with code_snippet is ready to run with:\n")
print("\tjupyter lab\n")

# remove unnecessary directories when using the binder
_('rm', '-rf', './lib')
_('rm', '-rf', './src')
_('rm', '-rf', './style')
_('rm', '-rf', './_temp_extension')
_('rm', '-rf', './Design')
_('rm', '-rf', './binder')
_('rm', '-rf', './docs')
_('rm', '-rf', './code_snippet')
_('rm', '-rf', './code_snippet.egg-info')
_('rm', '-rf', './schema')
_('rm', '-rf', './node_modules')
_('rm', './install.json')
_('rm', './package.json')
_('rm', './PROGRESS.md')
_('rm', './setup.py')
_('rm', './pyproject.toml')
_('rm', './tsconfig.json')
_('rm', './tsconfig.tsbuildinfo')
_('rm', './yarn.lock')
_('rm', './MANIFEST.in')
2 changes: 1 addition & 1 deletion binder/requirements.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
jupyterlab>=2.0
jupyterlab>=3.0
2 changes: 1 addition & 1 deletion binder/workspace.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"data":{"layout-restorer:data":{"main":{"dock":{"type":"tab-area","currentIndex":0,"widgets":["notebook:Untitled2.ipynb"]},"mode":"multiple-document","current":"notebook:Untitled2.ipynb"},"left":{"collapsed":false,"current":"code-snippet-extension","widgets":["filebrowser","running-sessions","command-palette","jp-property-inspector","tab-manager","code-snippet-extension","extensionmanager.main-view"]},"right":{"collapsed":true,"widgets":[]}},"file-browser-filebrowser:cwd":{"path":""},"notebook:Untitled2.ipynb":{"data":{"path":"Untitled2.ipynb","factory":"Notebook"}}},"metadata":{"id":"/lab"}}
{"data":{"layout-restorer:data":{"main":{"dock":{"type":"tab-area","currentIndex":1,"widgets":["notebook:Untitled.ipynb"]},"mode":"multiple-document","current":"notebook:Untitled.ipynb"},"left":{"collapsed":false,"current":"code-snippet-extension","widgets":["filebrowser","running-sessions","command-palette","jp-property-inspector","tab-manager","code-snippet-extension","extensionmanager.main-view"]},"right":{"collapsed":true,"widgets":[]}},"file-browser-filebrowser:cwd":{"path":""},"@jupyterlab/settingeditor-extension:plugin":{"sizes":[0.09057971014492754,0.9094202898550725],"container":{"plugin":"@jupyterlab/shortcuts-extension:shortcuts","sizes":[0.48376993166287013,0.5162300683371298]}},"notebook:Untitled.ipynb":{"data":{"path":"Untitled.ipynb","factory":"Notebook"}}},"metadata":{"id":"/lab"}}