How to see all installed packages? + a few other `Pkg` related questions

  1. I have more than a hundred packages installed. But Pkg.installed() only lists some 40 due to the size of the terminal window. How can I see all installed packages?

  2. Also, how can I have the installed packages printed alphabetically using Pkg.installed()? It’s hard to pick ham from peas.

  3. It takes more than 5 minutes on my machine for Pkg.installed() to return. Is this normal?

  4. Is there a way to see all registered Julia packages on the METADATA git page: The last 277 packages are not see-able on that page.

  5. I use a package which is registered with METADATA. But I don’t use its tagged version, since it’s too old. I use the development version that I checked out from its git repo. However, each time when I Pkg.update(), the tagged version is installed automatically and overrides the version I intend to use. This really drive me nuts as I have to manually Pkg.rm the tagged version. Is there a way to avoid this?

Sorry to be lengthy. Thanks!!


I’ll try and answer these questions, though I’m no expert.

  • Pkg.installed() returns a Dict, so you could pass it to the sort function and also write a loop to see the list a few lines at a time, or just list all the keys in alphabetical order


  • It will probably be O(n) on the number of packages since it’s a file-system operation to look through all packages on disk

  • git clone and then view the file locally. The limitation on what you see on the github page is imposed by github.

  • Try to pin the package to the version you want, or Pkg.checkout to always stay on the latest version.


sort(collect(Pkg.installed())) will print them in sorted order. show(STDOUT, "text/plain", sort(collect(Pkg.installed()))) will print them all, but it would be nice to have something better by default.

Are you using Windows? Julia’s package system currently uses lots of little files in the METADATA repo to store metadata, which is pretty slow on Windows (it was even worse before we switched to libgit in Julia 0.5). At some point we are hoping to switch to a new package metadata system that will eliminate this problem (

Normally I would recommend looking at the listing at

To see the github listing directly you may have to clone the repo, or do print(readdir(Pkg.dir("METADATA"))) in Julia.

Normally if you do Pkg.checkout("somepackage"), then update() will stay on the master release. Is that not working?


A faster way to access the installed packages can be to read all directories in Pkg.dir()


Please note that there are some extra directories in it (like .cache, .trash, and METADATA). If you want to print them all alphabetically:


1 Like


I’m inclined not to clone the repo. I think @stevengj’s method works better for me.

Thanks for the tip!

Yes. It’ll be more convenient if something like show(STDOUT, "text/plain", sort(collect(Pkg.installed()))) can be set as default or at least be able to be opt for.

No. I’m on Ubuntu. I think it’s more or less because my machine is old and was running something else at the same time, though it’s definitely on the scale of minutes rather than seconds.

This works perfectly.

Thanks for the tip!

Yes, it’s indeed quicker than Pkg.installed(), as I usually don’t care much about the version tags. Thanks!

Pkg.dir() only lists the first package directory. This doesn’t work if you have multiple package directories.

1 Like

Thanks for pointing out. I wasn’t aware of this.

filter((x) -> typeof(eval(x)) <: Module && x ≠ :Main, names(Main,imported=true))

To answer (1) and (2): Pkg.status()

This was the best option for me on Julia v1.2.0.