davidchambers
davidchambers

Reputation: 24846

How do I list all available versions of a port?

I can run:

$ port info nodejs

This tells me that the current version of the nodejs port is 4.2.2.

Which command should I run to list all versions of a port?

Upvotes: 5

Views: 6964

Answers (2)

augurar
augurar

Reputation: 13056

You can see what versions are installed on your computer using port installed <portname>. To activate a specific installed version, you can use port activate <portname> @<version>.

If you want to see all past versions of a port, even those that are not installed, then you'll need to inspect the source code repository. See the wiki for further information: How to install an older version of a port.

Upvotes: 2

m7thon
m7thon

Reputation: 3043

In fact, port info nodejs already lists all available versions of a port, since MacPorts only provides a single version of any port at a given time, namely the current one.

That being said, if you for some reason require an older version of a port, you can follow these instructions on the MacPorts wiki. Basically, you need to get the Portfile from an older revision of the MacPorts svn and install it manually.

The best you can do to see what "versions" of a port have existed is to browse the svn log for that port.

Upvotes: 2

Related Questions