Generating a list of all installed software (or something like that).

Anders F Björklund afb at macports.org
Fri Dec 5 05:04:36 PST 2008


Tim Visher wrote:

> I'd be interested in generating a complete list of all software I have
> installed through MacPorts so that I don't have to back up my
> installation in case of a hard drive failure.  Basic use case would be
> that if my disk fails, I just download MacPorts again, and then run
> this script through it and after awhile I get my exact install back
> the way I had it n-days before the crash.  Any way to do this?

sudo port archive installed

You'd need to enable "archive mode" first though (in macports.conf).
And if you had "auto clean" enabled, probably rebuild everything too.

If you don't want to save the binaries, but only the list of what
you had installed then save this output to a file for later use:

port installed > installed.txt

>
> This has been inspired by APTonCD's ability to generate a list of
> everything you've installed through apt for various purposes, if you
> want to know an analogue.

There's some DEB building support as well, but it is pretty flaky...
(and you can't install .deb packages so that they use the registry)

--anders



More information about the macports-users mailing list