Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@hndr91
Created March 9, 2017 09:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save hndr91/9597a5cbb6ee8f8a56a0802d3ddeeae8 to your computer and use it in GitHub Desktop.
Save hndr91/9597a5cbb6ee8f8a56a0802d3ddeeae8 to your computer and use it in GitHub Desktop.
import pip
installed_packages = pip.get_installed_distributions()
installed_packages_list = sorted(["%s==%s" % (i.key, i.version)
for i in installed_packages])
print(installed_packages_list)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment