Virtualenv / pip installation log?

2019-06-17 10:38发布

Do pip or virtualenv keep a log of installations?

E.g. Say I create a virtualenv and install a package in it.

> source [my virtual env]/bin/activate
> pip install matplotlib

Is there a place where a log of the package installation is kept?

If not, what would be a good way to log package installations ? (other than manually copying the output of pip install to a text file)

2条回答
可以哭但决不认输i
2楼-- · 2019-06-17 11:11

If you care about keeping the logs, you probably care also about pip's verbose option

查看更多
该账号已被封号
3楼-- · 2019-06-17 11:14

When you run the pip, you can specify the logfile.

pip install matplotlib --log LOG_FILE

That file will contain the verbose log

for example,

pip install matplotlib --log log.txt

This will create a log.txt in the same directory and put the log in that.

查看更多
登录 后发表回答