Skip to main content

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

Project description

jupyter-ruff

PyPI Version Conda 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 one of the following:

pip install jupyter-ruff
mamba install jupyter-ruff -c conda-forge

To remove the extension, execute one of the following:

pip uninstall jupyter-ruff
mamba remove 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.3.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.3.0-py3-none-any.whl (3.2 MB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: jupyter_ruff-0.3.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.10

File hashes

Hashes for jupyter_ruff-0.3.0.tar.gz
Algorithm Hash digest
SHA256 e9bb9e1a4538fd6624cd19d892da1538397628a8e9263851734c0c733acc7272
MD5 f95157c31e3c5d36b87b76596a39673f
BLAKE2b-256 ae059db5f7974e4bd339f36f0e9bebcf1e6f79efe15ce0a0b0e1cb3630de2e58

See more details on using hashes here.

File details

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

File metadata

  • Download URL: jupyter_ruff-0.3.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.10

File hashes

Hashes for jupyter_ruff-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 7183f74c9c1b6853894166ff1ce2e55f6aa3f8908518efeeeed03a7869c734e4
MD5 65d69f95055fa84742553818b7fccc11
BLAKE2b-256 0a9e9fe9571c32a1367c7f6fb6150484da4728eb7035e54425b35e9ab132cac3

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