Skip to main content

A JupyterLab and Jupyter Notebook extension for formatting code with Ruff.

Project description

jupyter-ruff

PyPI Version NPM Version GitHub Actions Workflow Status Binder

A JupyterLab and Jupyter Notebook extension for formatting code with Ruff.

Requirements

One of the following:

  • JupyterLab >= 4.0.0
  • Jupyter Notebook >= 7.0.0

Usage

An interactive environment to try out this extension is available on Binder. Alternatively, learn how to use this extension by reading the Demo.ipynb notebook.

If you are familiar with nb_black, this extension can provide a similar mode of operation where cells are formatted as they are executed. However, you also have the option to just format cells using menus, keyboard shortcuts, the command palette, or format on save.

You may also consult the Ruff documentation to learn about the underlying formatting rules.

Install

To install the extension, execute:

pip install jupyter-ruff

To remove the extension, execute:

pip uninstall jupyter-ruff

Alternatively, you can also use the builtin JupyterLab extension manager to install the extension.

Contributing

All good-faith contributions are welcome! Please read CONTRIBUTING for information on how to set up a development environment and perform common development tasks.

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

jupyter_ruff-0.2.0.tar.gz (3.3 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

jupyter_ruff-0.2.0-py3-none-any.whl (3.2 MB view details)

Uploaded Python 3

File details

Details for the file jupyter_ruff-0.2.0.tar.gz.

File metadata

  • Download URL: jupyter_ruff-0.2.0.tar.gz
  • Upload date:
  • Size: 3.3 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.8

File hashes

Hashes for jupyter_ruff-0.2.0.tar.gz
Algorithm Hash digest
SHA256 537a5359b6d322c2d51b905c712dc4719c8472414cf1b90f22a3360536f97cd2
MD5 4e282987f4beafaaa902290449b60e57
BLAKE2b-256 755c347a39f910a2c7182d064bf90cc30ae654801eedff7fbc1d0f7ccee826fa

See more details on using hashes here.

File details

Details for the file jupyter_ruff-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: jupyter_ruff-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 3.2 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.8

File hashes

Hashes for jupyter_ruff-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 97a8d951c13cb16c109cc493bc796684ced740c7991c06521916d2d944431dca
MD5 c734630189f15b41c6e5dfc86971f55d
BLAKE2b-256 0b7b8d080821d48cefef70c195031ac9fc823e06f5ff69a5e0febf72f28f611f

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page