nb-black-formatter


Namenb-black-formatter JSON
Version 1.0.1 PyPI version JSON
download
home_pagehttps://github.com/dnanhkhoa/nb_black
SummaryA simple extension for Jupyter Notebook and Jupyter Lab to beautify Python code automatically using Black.
upload_time2024-03-20 10:11:04
maintainerNone
docs_urlNone
authorKhoa Duong
requires_pythonNone
licenseMIT
keywords black-formatter black-beautifier black jupyterlab-extension jupyter-notebook-extension
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # nb_black-formatter

[![PyPI](https://img.shields.io/pypi/v/nb_black.svg)](https://pypi.org/project/nb-black/)
[![PyPI - Python Version](https://img.shields.io/pypi/pyversions/nb_black.svg)](https://pypi.org/project/nb-black/)

A simple extension for Jupyter Notebook and Jupyter Lab to beautify Python code automatically using **[Black](https://github.com/psf/black)**.

Please note that since the **Black** package only supports Python 3.6+, so **[YAPF](https://github.com/google/yapf)** package will
be used for the lower versions. If you edit the code while running the cell, the formatting is
not submitted to the Jupyter notebook and instead silently suppressed, so you have to stick with
the edited, but unformatted code.

## Installation

You can install this package using [pip](http://www.pip-installer.org):

```sh
[sudo] pip install nb-black-formatter
```

## Usage

For Jupyter Notebook:

```sh
%load_ext nb_black
```

For Jupyter Lab:

```sh
%load_ext lab_black
```

Just put this code into the first cell in your Notebook, and that's all. :)

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/dnanhkhoa/nb_black",
    "name": "nb-black-formatter",
    "maintainer": null,
    "docs_url": null,
    "requires_python": null,
    "maintainer_email": null,
    "keywords": "black-formatter black-beautifier black jupyterlab-extension jupyter-notebook-extension",
    "author": "Khoa Duong",
    "author_email": "dnanhkhoa@live.com",
    "download_url": "https://files.pythonhosted.org/packages/74/6c/f05248450ee5dd4c20829ccc655781a23269e3992d5878605e6d7c8fb224/nb_black_formatter-1.0.1.tar.gz",
    "platform": null,
    "description": "# nb_black-formatter\n\n[![PyPI](https://img.shields.io/pypi/v/nb_black.svg)](https://pypi.org/project/nb-black/)\n[![PyPI - Python Version](https://img.shields.io/pypi/pyversions/nb_black.svg)](https://pypi.org/project/nb-black/)\n\nA simple extension for Jupyter Notebook and Jupyter Lab to beautify Python code automatically using **[Black](https://github.com/psf/black)**.\n\nPlease note that since the **Black** package only supports Python 3.6+, so **[YAPF](https://github.com/google/yapf)** package will\nbe used for the lower versions. If you edit the code while running the cell, the formatting is\nnot submitted to the Jupyter notebook and instead silently suppressed, so you have to stick with\nthe edited, but unformatted code.\n\n## Installation\n\nYou can install this package using [pip](http://www.pip-installer.org):\n\n```sh\n[sudo] pip install nb-black-formatter\n```\n\n## Usage\n\nFor Jupyter Notebook:\n\n```sh\n%load_ext nb_black\n```\n\nFor Jupyter Lab:\n\n```sh\n%load_ext lab_black\n```\n\nJust put this code into the first cell in your Notebook, and that's all. :)\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "A simple extension for Jupyter Notebook and Jupyter Lab to beautify Python code automatically using Black.",
    "version": "1.0.1",
    "project_urls": {
        "Homepage": "https://github.com/dnanhkhoa/nb_black"
    },
    "split_keywords": [
        "black-formatter",
        "black-beautifier",
        "black",
        "jupyterlab-extension",
        "jupyter-notebook-extension"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "746cf05248450ee5dd4c20829ccc655781a23269e3992d5878605e6d7c8fb224",
                "md5": "e7bd49be92dab759fbbfbbfc2a7feafa",
                "sha256": "24153ab7e381cec202319ef0087ac0ae85a161d1e8e30f53c246d4782b9d4d40"
            },
            "downloads": -1,
            "filename": "nb_black_formatter-1.0.1.tar.gz",
            "has_sig": false,
            "md5_digest": "e7bd49be92dab759fbbfbbfc2a7feafa",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 5106,
            "upload_time": "2024-03-20T10:11:04",
            "upload_time_iso_8601": "2024-03-20T10:11:04.769199Z",
            "url": "https://files.pythonhosted.org/packages/74/6c/f05248450ee5dd4c20829ccc655781a23269e3992d5878605e6d7c8fb224/nb_black_formatter-1.0.1.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-03-20 10:11:04",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "dnanhkhoa",
    "github_project": "nb_black",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "lcname": "nb-black-formatter"
}
        
Elapsed time: 0.21475s