Providing code formatting and import sorting for python codes using
Pyformat will read your "python.pythonPath" configuration to choose correct python environment.
isort must be installed in your selected python environment.
There's some reason that I can't use the official vscode-python, so I created this extension for myself.
* Arguments passed to autopep8, defaults to ["--max-line-length 120"].
* See https://github.com/hhatto/autopep8#configuration for more info.
* Arguments passed to isort, defaults to [ "-w 120", "-m 2" ].
* See https://github.com/timothycrosley/isort#configuring-isort for more info.
* Enable import organization functionality. defaults to true.
* You can turn this off if you already have other extensions deals with your import for python files.
* The command "pyformat.sortImports" will still be available even this is disabled.
Format and sort imports on save
Adding the following settings in your project or global settings.
/** Enable format on save */
/** Pyformat use it's own code action to prevent confliction with other tools. */