how to ignore the assignment intendation in any python formatter (black, yapf, autopep8)

64 Views Asked by At

i would like my code to look like following:

short          = value
long_name      = value
very_long_name = value

instead all python formatter give the following result:

short = value
long_name = value
very_long_name = value

the latter is harder to read in my opinion, so i would like to skip assignment indentations. To my knowledge, there are no settings for such a configuration. Neither for autopep, yapf and black.

with black I had tried --skip-string-normalisation, but it didn't do anything

with autopep8 I had tried severall options, --ignore E20, E221, E251 ... but none worked https://pypi.org/project/autopep8/#features

0

There are 0 best solutions below