Skip to content

Instantly share code, notes, and snippets.

@ncalm
Created September 19, 2024 13:27
Show Gist options
  • Save ncalm/39a6da8ce1579de8eb3c198965506c01 to your computer and use it in GitHub Desktop.
Save ncalm/39a6da8ce1579de8eb3c198965506c01 to your computer and use it in GitHub Desktop.
Use this short script in Python in Excel to spill the list of available libraries to the grid
import subprocess
result = subprocess.run(['pip', 'list'], capture_output=True, text=True)
lines = result.stdout.splitlines()[2:]
[tuple(line.split()[:2]) for line in lines]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment