In the Eclipse External Tool Configuration window, I set Flake8 up as follows:
- Location:
/usr/bin/flake8
- Working Directory: empty
- Arguments:
--format="%(code)s %(text)s [%(path)s:%(row)d:%(col)d]" ${project_loc}
With this Flake8 format, the information about the error is printed first and the location second.
I could not figure out a way to get Eclipse to print a proper relative directory (Even using ${resource_path}
printed a leading slash). Nor could I figure out how to get GrepConsole's base directory setting to read from an Eclipse variable. The result with the default Flake 8 format was that in order for everything to work, I had to use absolute path names which crowded all the useful information out of the immediately visible portion of the console. With the custom format, the interesting stuff comes first and the dross is at the end.
GrepConsole can be installed via the Eclipse update site at http://eclipse.schedenig.name
Inspired by http://stackoverflow.com/a/17053592