Skip to content

Welcome to pypi-command-line documentation

pypi-command-line is a powerful command line interface for pypi.org

What is this?

It's a command line interface[?] (CLI) that you can use to run commands[?] in a terminal[?]

Why is this?

There are a few alternatives (namely pypi-cli and pypi-client) that I've come across but none of those offer the same amount of functionality and beautifulness[?] or even the same amount of speed.

Installation and Usage

  • For installation instructions see installation for instructions.
  • For usage details see usage

Alternatives

pypi-cli

Now this probably was the best option before pypi-command-line came out and it does have some flaws. The information command of pypi-cli is pretty minimal, there's no way of seeing the github information, The download count doesn't work properly, the long descriptions aren't formatted at all with pypi-cli. pypi-cli uses the xml-rpc[?] API that is discontinued So the search feature doesn't work anymore, . The stat command is broken and is badly formatted for screens that are not ultra wide. And the project is unmaintained and archived

TL;DR The stat and search commands don't work anymore, the information command kinda works but the download count doesn't work, can't see github information, descriptions are raw.

pypi-client

So this can just search for packages on pypi and thats it. Now don't you think that this is inherently bad as per say. So I tried it out immediately and it just got stuck loading the packages, pypi-client gets names of all the packages that exist pypi which took like 4 mins, then I assume it downloads the github stars data? Which takes like another 3 mins and then It just asked me to authorize with github… like why does pypi-client even need authorization from me since github has a public api. And then it showed this which isn't really unreadable just badly formatted for screens that are not ultra wide. by changing the font size a bit I could make it look like this which still isn't bad just a bit convoluted. And even at the end of the day the results are manually searched through therefore different from pypi

TL;DR: Takes too long (≈7 mins), Needs github authorization, badly formatted for non ultra wide monitors, searches manually so results are different compared to pypi

TL;DR: Takes too long (≈7 mins), Needs github authorization, badly formatted for non ultra-high-end monitors, searches manually so results are different compared to pypi

Benchmarks for speed

… search discord

  • pypi-command-line - 1.4221807

    Takes around 1.5 secs to do a get request to the pypi search page then parse and return the results so that the results are the exact same as shown in pypi.org

  • pypi-client - 7.4170682

    Takes 7 secs to get all packages and show ones containing discord, pypi-command-line can achieve the same result in 1.22[*] seconds using pypi regex-search discord (the command allows you to search with regex)

  • pypi-cli - doesn't work anymore

    The command doesn't work anymore since pypi has discontinued it's xml-rpc api

… information django

  • pypi-cli - 0.9757808

    Now I do have to admit that this is faster, mainly because this does a single api call but mine does 3. You do have to realise that you are getting this instead of this

  • pypi-command-line - 2.0484411

    This does take longer but it's using that time to get not only the pypi stats but the proper download stats and github stats along with the pypi stats, disabling those lowers this time to 1.35[*] seconds.

  • pypi-client - can't see information

    You can't see project information with this package, you can only search for stuff.

Notes: https://wasi-master.github.io/pypi-command-line/notes

Back to top