Added handling for both mercurial and git repos and also using the config files for pep8 and pylint.