Commit 617e9047 authored by Joseph Weston's avatar Joseph Weston

Merge branch 'jbweston-master-patch-09884' into 'master'

add jupyterlab_git, jupyterlab_code_formatter, jupyterlab-lsp, jupyterlab-toc, collapsible-headings and nbgitpuller extensions

See merge request !9
parents e6ff1d6e 9c5dfb28
Pipeline #24029 failed with stages
in 30 minutes and 43 seconds
# Things are broken since the base notebook was upgraded to Ubuntu 18.04
# TODO: fix this properly, but for now we just pin the upstream image
FROM jupyter/base-notebook:5b2160dfd919
FROM jupyter/base-notebook
USER root
WORKDIR /
......@@ -68,13 +66,28 @@ RUN conda env update -n root -f /environments/python3.yml && \
# Add a dev environment (e.g. with dev kwant and holoviews)
# RUN conda env create -p /opt/conda/envs/dev -f /environments/dev.yml
# Enable `jupyter nbextension`s
RUN jupyter nbextension enable --py --sys-prefix ipyparallel && \
jupyter nbextension enable --py --sys-prefix jupyter_cms && \
jupyter nbextension enable --py --sys-prefix nbserverproxy && \
jupyter labextension install @jupyter-widgets/jupyterlab-manager \
@jupyterlab/katex-extension @jupyterlab/latex \
jupyterlab_bokeh @pyviz/jupyterlab_pyviz
jupyter serverextension enable --sys-prefix jupyter_server_proxy && \
jupyter serverextension enable --py --sys-prefix jupyterlab_code_formatter && \
jupyter serverextension enable --sys-prefix nbgitpuller && \
jupyter serverextension enable --py --sys-prefix jupyterlab_git && \
jupyter serverextension enable --sys-prefix --py jupyter_lsp && \
jupyter labextension install \
@jupyter-widgets/jupyterlab-manager \
@jupyterlab/katex-extension \
@jupyterlab/latex \
jupyterlab_bokeh \
@pyviz/jupyterlab_pyviz \
@ryantam626/jupyterlab_code_formatter \
@jupyterlab/git \
@krassowski/jupyterlab-lsp \
@jupyterlab/toc \
@aquirdturtle/collapsible_headings \
&& \
jupyter lab build # apparently jupyterlab-git needs this
# prevent nb_conda_kernels from overriding our custom kernel manager
RUN rm /opt/conda/etc/jupyter/jupyter_notebook_config.json
......@@ -84,6 +97,10 @@ COPY jupyter_notebook_config.py /opt/conda/etc/jupyter/
# Register nbdime as a git diff and merge tool
COPY git* /etc/
# We use git from Conda, so ensure we install the system
# git config and attributes into the appropriate /etc
RUN cat /etc/gitconfig >> /opt/conda/etc/gitconfig && \
cat /etc/gitattributes >> /opt/conda/etc/gitattributes
# Create parallel profiles and copy the correct config
RUN ipython profile create --parallel --profile python3 --ipython-dir /opt/conda/etc/ipython
......
......@@ -27,5 +27,8 @@ NBApp.nbserver_extensions = {
"jupyterlab": True,
"jupyter_cms": True,
"ipyparallel.nbextension": True,
"nbserverproxy": True,
"jupyter_server_proxy": True,
"jupyterlab_black": True,
"jupyterlab_git": True,
"nbgitpuller": True,
}
......@@ -2,3 +2,5 @@
# add conda to default PATH
export PATH="/opt/conda/bin/:$PATH"
# make nano the default editor
export EDITOR="nano"
......@@ -22,12 +22,14 @@ dependencies:
# jupyter tools and extensions
- jupyterhub
- jupyter_cms
- jupyterlab
- jupyterlab=1.0* # upgrade to 1.2* when collapsible headings is fixed
- jupyter-server-proxy
- jupytext
- jupyterlab-git
- jupyterlab_code_formatter
- line_profiler
- nbdime
- nbstripout
- nbserverproxy
- nb_conda
- mistune
# other
......@@ -54,3 +56,7 @@ dependencies:
- git+https://github.com/basnijholt/adaptive-tools
- qtplot
- python-gitlab
- nbgitpuller
# for nice autocompletion and jump-to-definition in Jupyterlab
- jupyter-lsp
- python-language-server[all]
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment