{"id":17191170,"url":"https://github.com/dfm/black_nbconvert","last_synced_at":"2025-04-13T19:31:08.763Z","repository":{"id":35176711,"uuid":"212234079","full_name":"dfm/black_nbconvert","owner":"dfm","description":"Apply black to ipynb files","archived":false,"fork":false,"pushed_at":"2025-03-03T20:05:51.000Z","size":49,"stargazers_count":46,"open_issues_count":3,"forks_count":3,"subscribers_count":4,"default_branch":"main","last_synced_at":"2025-04-11T05:39:46.059Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dfm.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-10-02T01:41:48.000Z","updated_at":"2024-12-07T21:24:30.000Z","dependencies_parsed_at":"2023-02-17T22:46:04.292Z","dependency_job_id":"8a8d6e1f-3cd8-401e-9ca4-28b7b8fddda6","html_url":"https://github.com/dfm/black_nbconvert","commit_stats":{"total_commits":37,"total_committers":3,"mean_commits":"12.333333333333334","dds":"0.45945945945945943","last_synced_commit":"30939c3414408d86a824509aa4f1c53da68bb457"},"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dfm%2Fblack_nbconvert","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dfm%2Fblack_nbconvert/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dfm%2Fblack_nbconvert/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dfm%2Fblack_nbconvert/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dfm","download_url":"https://codeload.github.com/dfm/black_nbconvert/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248767863,"owners_count":21158546,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-15T01:25:06.097Z","updated_at":"2025-04-13T19:31:08.444Z","avatar_url":"https://github.com/dfm.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# black natively supports Jupyter notebooks\r\n\r\n**This project is no longer necessary!**\r\n\r\nTo replace your `black_nbconvert` `pre-commit` configuration, use:\r\n\r\n```yaml\r\n  - repo: https://github.com/psf/black\r\n    rev: \"22.1.0\"\r\n    hooks:\r\n      - id: black-jupyter\r\n```\r\n\r\nIf you're still using this project, the original README is below:\r\n\r\n# black + nbconvert\r\n\r\nTired of having to *think* about formatting in Jupyter notebooks?\r\nLook no further!\r\nThis script will correctly format your Jupyter notebooks for you using [black](https://black.readthedocs.io).\r\n\r\n**Warning: This project will overwrite your notebooks in place.\r\nIt shouldn't change anything except the format, but use at your own risk!**\r\n\r\n## Installation \u0026 Usage\r\n\r\nTo install:\r\n\r\n```bash\r\npip install black_nbconvert\r\n```\r\n\r\nTo check a notebook:\r\n\r\n```bash\r\nblack_nbconvert --check /path/to/a/notebook.ipynb\r\n```\r\n\r\nTo fix the formatting in a notebook (in place):\r\n\r\n```bash\r\nblack_nbconvert /path/to/a/notebook.ipynb\r\n```\r\n\r\nIf you pass a directory instead of a notebook file, notebooks will be found recursively below that directory.\r\nFor example:\r\n\r\n```bash\r\nblack_nbconvert .\r\n```\r\n\r\nwill fix the formatting for all notebooks in the current directory and (recursively) below.\r\n\r\n*Configuration:* Configuration for `black` in a `pyproject.toml` file above the target files will be respected.\r\n\r\n## Version control integration\r\n\r\nUse [pre-commit](https://pre-commit.com/).\r\nOnce you [have it installed](https://pre-commit.com/#install), add this to the `.pre-commit-config.yaml` in your repository:\r\n\r\n```yaml\r\nrepos:\r\n- repo: https://github.com/dfm/black_nbconvert\r\n  rev: v0.3.0\r\n  hooks:\r\n  - id: black_nbconvert\r\n```\r\n\r\nThen run `pre-commit install` and you're ready to go.\r\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdfm%2Fblack_nbconvert","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdfm%2Fblack_nbconvert","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdfm%2Fblack_nbconvert/lists"}