python - Get date and time of installation for packages installed via pip -
i find way calendar date , time in hour:minute:seconds format packages installed via pip.
i able see in output like: month/day/year - hour:minute:seconds each package.
thanks!
is looking -
import pip import os import time in [139]: package in pip.get_installed_distributions(): .....: print "%s: %s" % (package, time.ctime(os.path.getctime(package.location))) .....: pyudev 0.17.dev20150317: tue mar 17 12:02:58 2015 python-magic 0.4.6: fri mar 20 14:07:59 2015 runipy 0.1.0: fri oct 31 01:49:34 2014
source of code - https://stackoverflow.com/a/24736563/170005
you can import pip
too, pretty interesting. didn't know this.
Comments
Post a Comment