Create Python Files from JupyterLab
Project description
jupyterlab-python-file
Create Python Files from JupyterLab
Prerequisites
- JupyterLab 1.0+
Installation
For JupyterLab 3.x, the extension can be installed with pip
:
pip install jupyterlab-python-file
Or with conda
:
conda install -c conda-forge jupyterlab-python-file
# or with mamba
mamba install jupyterlab-python-file
For JupyterLab 1.x and 2.x:
jupyter labextension install jupyterlab-python-file
Development
Note: You will need NodeJS to build the extension package.
The jlpm
command is JupyterLab's pinned version of
yarn that is installed with JupyterLab. You may use
yarn
or npm
in lieu of jlpm
below.
# Clone the repo to your local environment
# Change directory to the jupyterlab-python-file directory
# create a new environment
conda create -n jupyterlab-python-file -c conda-forge python nodejs -y
conda activate jupyterlab-python-file
# install the JupyterLab pre-release
python -m pip install --pre jupyterlab
# Install package in development mode
pip install -e .
# Link your development version of the extension with JupyterLab
jupyter labextension develop . --overwrite
# Rebuild extension Typescript source after making changes
jlpm run build
You can watch the source directory and run JupyterLab at the same time in different terminals to watch for changes in the extension's source and automatically rebuild the extension.
# Watch the source directory in one terminal, automatically rebuilding when needed
jlpm run watch
# Run JupyterLab in another terminal
jupyter lab
With the watch command running, every saved change will immediately be built locally and available in your running JupyterLab. Refresh JupyterLab to load the change in your browser (you may need to wait several seconds for the extension to be rebuilt).
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for jupyterlab-python-file-0.5.1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 27dd214bb63087fbdfa83d4a5286292325394c6a3cd1d7ee7ec9ace36510abc7 |
|
MD5 | 75c2a38d8605536660beb622e2da062c |
|
BLAKE2b-256 | e193e6cf054cde43528503f87cd774ac1ada25a3bbf050c0008dd5825b93d076 |
Hashes for jupyterlab_python_file-0.5.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 72330464274e8a0d5ff5efe9a5954071b15b5fd772934ec89db34ca5d8c1aea5 |
|
MD5 | 0f36f9a623a5cfca24de158bd73557f4 |
|
BLAKE2b-256 | c3d4df114c7673bd97897f0c912111e79f1d9c041c6bac6835d686881cf7cc5f |