Suggested port command enhancement?

Rainer Müller raimue at macports.org
Tue Jun 3 18:05:38 PDT 2008


Ryan Schmidt wrote:
> With the new "port distfiles" target, I think it could be implemented  
> like this:
> 
> 1. Get the list of all distfiles (find /opt/local/var/macports/ 
> distfiles -type f)
> 2. Get the list of installed ports (port installed)
> 3. For each installed port foo, get the list of distfiles (port  
> distfiles foo) and remove them from the list of distfiles
> 4. All the distfiles that are left in the list at the end aren't used  
> for any installed port and can be removed to save space

Already possible:
$ sudo port mirror installed
$ sudo portmirror

This should delete any unneeded distfiles. But I agree that this is not 
really obvious, especially as it requires the use of port mirror instead 
of port fetch.

But usually you don't need any distfile again, so cleaning them all is 
mostly save:
$ sudo port clean --dist installed
Or even:
$ sudo port clean --dist all

Rainer


More information about the macports-users mailing list