Skip 'pipdeptree' itself when displaying the tree

This commit is contained in:
Vineet 2014-02-05 21:42:43 +05:30
parent af7bc5e9b4
commit ccd9529c32
1 changed files with 4 additions and 2 deletions

View File

@ -90,8 +90,10 @@ def main():
'current virtualenv, if in a virtualenv'
))
args = parser.parse_args()
print(render_tree(pip.get_installed_distributions(local_only=args.local_only),
list_all=args.all))
default_skip = ['setuptools', 'pip', 'python', 'distribute']
packages = pip.get_installed_distributions(local_only=args.local_only,
skip=default_skip+['pipdeptree'])
print(render_tree(packages, list_all=args.all))
return 0