python软件包管理工具pip的简单使用和说明
Posted
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了python软件包管理工具pip的简单使用和说明相关的知识,希望对你有一定的参考价值。
在学习python爬虫的时候需要用到一个builtwith模块,但是我在导入的时候发现没有这个模块,就需要下载这个模块, 有一个很好的工具叫pip,这是python软件包的管理工具,可以安装,卸载,更新软件包。下面让我们一起来看看这个工具把
1:下载并安装pip
[[email protected] love]# wget "https://pypi.python.org/packages/source/p/pip/pip-1.5.4.tar.gz#md5=834b2904f92d46aaa333267fb1c922bb" --no-check-certificate [[email protected] love]# tar -zxf pip-1.5.4.tar.gz [[email protected] love]# cd pip-1.5.4 [[email protected] love]# python setup.py install
2:使用pip下载builtwith包
[[email protected] love]# pip install builtwith
用法:
pip <command> [options]
下边的是通过 [[email protected] love]# pip --help得到的
Commands:
install Install packages.
uninstall Uninstall packages.
freeze Output installed packages in requirements format.
list List installed packages.
show Show information about installed packages.
search Search PyPI for packages.
wheel Build wheels from your requirements.
zip DEPRECATED. Zip individual packages.
unzip DEPRECATED. Unzip individual packages.
bundle DEPRECATED. Create pybundles.
help Show help for commands.
General Options:
-h, --help Show help.
-v, --verbose Give more output. Option is additive, and can be used up
to 3 times.
-V, --version Show version and exit.
-q, --quiet Give less output.
--log-file <path> Path to a verbose non-appending log, that only logs
failures. This log is active by default at
/root/.pip/pip.log.
--log <path> Path to a verbose appending log. This log is inactive by
default.
--proxy <proxy> Specify a proxy in the form
[user:[email protected]]proxy.server:port.
--timeout <sec> Set the socket timeout (default 15 seconds).
--exists-action <action> Default action when a path already exists: (s)witch,
(i)gnore, (w)ipe, (b)ackup.
--cert <path> Path to alternate CA bundle
本文出自 “庭中有奇树” 博客,请务必保留此出处http://zhangdl.blog.51cto.com/11050780/1872702
以上是关于python软件包管理工具pip的简单使用和说明的主要内容,如果未能解决你的问题,请参考以下文章