CmdID

CmdID / Commands

black

Format Python code automatically. tldr-pages

On several platforms

Opens CmdID with your command. It is read in your browser and sent nowhere.

Several platforms

from tldr-pages, CC BY 4.0

Auto-format a file or entire directory

black path/to/file_or_directoryIdentify

Format the code passed in as a string

black --code "code"Identify

Show whether a file or a directory would have changes made to them if they were to be formatted

black --check path/to/file_or_directoryIdentify

Simulate formatting a file or a directory and show the changes that would be made

black --diff path/to/file_or_directoryIdentify

Auto-format a file or directory, emitting exclusively error messages to stderr

black --quiet path/to/file_or_directoryIdentify

Auto-format a file or directory without replacing single quotes with double quotes (adoption helper, avoid using this for new projects)

black --skip-string-normalization path/to/file_or_directoryIdentify