isort#

We’re using isort to sort the Python import statements.

isort config#

Please have a look at the isort config for all configured options.

Hint

To see all available configuration options, have a look at the isort documentation.

isort Makefile#

To run isort in your project, use the following Makefile targets:

LINTER_CONFIGS = https://git.confirm.ch/confirm/guidelines/raw/master/configs

isort:
    curl -sSfLo .isort.cfg $(LINTER_CONFIGS)/isort.cfg
    isort $(SOURCE_DIR)

test-isort:
    curl -sSfLo .isort.cfg $(LINTER_CONFIGS)/isort.cfg
    isort -c --diff $(SOURCE_DIR)