Skip to main content

Use black with formate.

Project description

Use black with formate.

Tests

Linux Test Status Windows Test Status macOS Test Status Coverage

PyPI

PyPI - Package Version PyPI - Supported Python Versions PyPI - Supported Implementations PyPI - Wheel

Activity

GitHub last commit GitHub commits since tagged version Maintenance PyPI - Downloads

QA

CodeFactor Grade Flake8 Status mypy status

Other

License GitHub top language Requirements Status

Installation

formate-black can be installed from PyPI.

To install with pip:

$ python -m pip install formate-black

Hooks

formate-black provides a single hook for formate, which allows the black code formatter to be used.

black

Calls black, using the given keyword arguments as its configuration.

This hook only takes keyword arguments.

The max line length can be provided via the line_length keyword argument or in the config table as line_length.

The indent can also be set to tabs via the use_tabs keyword argument or in the config table as indent.

Example Configuration

[hooks]
reformat-generics = 40
collections-import-rewrite = 20
noqa-reformat = 60
ellipsis-reformat = 70

[hooks.black]
priority = 50

[hooks.black.kwargs]
string_normalization = false
magic_trailing_comma = false

[config]
indent = "\t"
line_length = 115

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

formate_black-0.2.0.tar.gz (4.7 kB view details)

Uploaded Source

Built Distribution

formate_black-0.2.0-py3-none-any.whl (13.3 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: formate_black-0.2.0.tar.gz
  • Upload date:
  • Size: 4.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.10.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.10

File hashes

Hashes for formate_black-0.2.0.tar.gz
Algorithm Hash digest
SHA256 9bf5af1baec9af4a1027e0186ccefc73f1c393d1190dd9f802aaba72e2eb4c5b
MD5 527369c68b282c4d63a2c6e2c62f8924
BLAKE2b-256 36821fb74add7618287146a913b2e2d3664108ce559ca75531e255ec05e4a1ea

See more details on using hashes here.

File details

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

File metadata

  • Download URL: formate_black-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 13.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.10.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.10

File hashes

Hashes for formate_black-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 edc4bb8bb8e14f50b7a7eda43a3597d6e3ef69576f628de0e9e8e6dfad216c4b
MD5 8d3ad0b53c0ac8f05e47a0d3eff4c0f4
BLAKE2b-256 465548f75ef70f2b49168c4cdd1b00caf5e045b3eda500656269a77ebf9f8287

See more details on using hashes here.

Supported by

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