Flake8Lint is a Sublime Text 2 plugin for check Python files against some of the style conventions in PEP8, PyFlakes and mccabe.
Based on bitbucket.org/tarek/flake8.
Download the latest source from GitHub and copy Flake8Lint folder to your ST2 "Packages" directory.
Or clone the repository to your ST2 "Packages" directory:
git clone git://github.com/dreadatour/Flake8Lint.git
The "Packages" directory is located at:
-
OS X:
~/Library/Application Support/Sublime Text 2/Packages/
-
Linux:
~/.config/sublime-text-2/Packages/
-
Windows:
%APPDATA%/Sublime Text 2/Packages/
Default Flake8Lint config: "Preferences" -> "Package Settings" -> "Flake8Lint" -> "Settings - Default"
{
// run flake8 lint on file saving
"lint_on_save": true,
// turn on pyflakes error lint
"pyflakes": true,
// turn on pep8 error lint
"pep8": true,
// turn off complexity check (set number > 0 to check complexity level)
"complexity": -1,
// select errors and warnings (e.g. ["E", "W6"])
"select": [],
//skip errors and warnings (e.g. ["E303", E4", "W"])
"ignore": []
}
To change default settings, go to "Preferences" -> "Package Settings" -> "Flake8Lint" -> "Settings - User" and paste default config to opened file.
Automatically check Python files with flake8 lint tool and show window with error list:
And move to error line/char on select.