我希望能够使用pip
(在终端上)搜索可用的Python包。我想要一个类似于Ubuntu中的apt-cache
的功能。更具体地说,我想
apt-cache search [package-name]
),发布于 2013-06-29 05:00:16
要搜索软件包,请发出以下命令
pip search [package-name]
发布于 2021-04-15 23:11:24
截至2020年12月14日,the pip search
functionality has been disabled:
$ pip search cast
ERROR: XMLRPC request failed [code: -32500]
RuntimeError: PyPI's XMLRPC API is currently disabled due to unmanageable load and will be deprecated in the near future. See https://status.python.org/ for more information.
这是我刚刚找到的一个名为pip_search的小工具,它可以执行简单的搜索,但它可以完成以下工作:
这是pip_search
v0.0.6的输出:
$ pip_search pulsemixer
---------------- -------------------------------------------------------------------------------
Name Description
pulsemixer pulsemixer - CLI and curses mixer for PulseAudio
pulsectl-asyncio Asyncio frontend for the pulsectl Python bindings of libpulse
pulsectl Python high-level interface and ctypes-based bindings for PulseAudio (libpulse)
---------------- -------------------------------------------------------------------------------
更新:pip_search
已经更新,每个文件夹都是每个项目的可点击(CTRL+click)地址,现在看起来是这样的:
$ pip_search pulsemixer
https://pypi.org/search/?q=pulsemixer
┏━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━┳━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
┃ Package ┃ Version ┃ Released ┃ Description ┃
┡━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━╇━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┩
│ pulsemixer │ 1.5.1 │ Apr 11, 2020 │ pulsemixer - CLI and curses mixer for PulseAudio │
│ pulsectl-asyncio │ 0.1.7 │ Jun 13, 2021 │ Asyncio frontend for the pulsectl Python bindings of libpulse │
│ pulsectl │ 21.5.18 │ May 22, 2021 │ Python high-level interface and ctypes-based bindings for PulseAudio (libpulse) │
└─────────────────────┴─────────┴──────────────┴─────────────────────────────────────────────────────────────────────────────────┘
要安装它,只需输入:pip install pip_search
还有另一个我刚刚尝试过的工具,叫做pypisearch。
要安装它,只需输入:pip install pypisearch
它是这样工作的:
$ python -m pypisearch pulsemixer
pulsemixer (1.5.1) [installed 1.5.0] pulsemixer - CLI and curses mixer for PulseAudio
pulsectl-asyncio (0.1.5) Asyncio frontend for the pulsectl Python bindings of libpulse
pulsectl (21.3.4) Python high-level interface and ctypes-based bindings for PulseAudio (libpulse)
发布于 2013-06-29 05:16:01
使用pip search QUERY
进行搜索的
使用pip help
和pip help COMMAND
了解所有可用命令及其选项。
可以在这里找到一个标记更简单的索引,以便更容易地自动消费:
https://stackoverflow.com/questions/17373473
复制相似问题