Minor refactor to simplify duplicated logic

Summary:
- Make each linter inherit from a shared Linter class
- Don't read all files in memory simultaneously
- Pass num_errors around instead of storing it as an instance var

Test Plan: runlint.py webapp/

Reviewers: csilvers

Reviewed By: csilvers

Differential Revision: http://phabricator.khanacademy.org/D4030