Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

pylint doesn't point to virtualenv python

I am pretty new to python and currenty I am trying to use pylint for checking code quality. I am getting a problem. My pylint doesn't point to virtualenv python interpreter. Here is the output that I get when I run pylint --version

 $ pylint --version    pylint 0.21.1,    astng 0.20.1, common 0.50.3    Python 2.6.6 (r266:84292, Jul 10 2013, 22:48:45)    [GCC 4.4.7 20120313 (Red Hat 4.4.7-3)] 

In virtualenv I have python 2.7 installed. Will appretiate you help if someone can point me to how to solve that.

like image 940
hjelpmig Avatar asked Jul 29 '13 11:07

hjelpmig


1 Answers

A cheap trick is to run (the global) pylint using the virtualenv python. You can do this using python $(which pylint) instead of just pylint. On zsh, you can also do python =pylint.

like image 192
Noufal Ibrahim Avatar answered Sep 23 '22 11:09

Noufal Ibrahim