users confusing selfupdate and sync

Mark Hattam mark at dxradio.demon.co.uk
Thu Oct 15 15:28:54 PDT 2009


On 15 Oct 2009, at 23:07, Olivier Le Floch wrote:

>>> The best might be to remind users that call "port sync" that "port  
>>> selfupdate" is the "usual" next step in updating ports. i.e. "port  
>>> sync" would end by displaying something like
>>>
>>>> "Portfiles successfully updated. To upgrade installed ports to  
>>>> their latest versions, please run port selfupdate."
>>
>> selfupdate doesn't update anything but update MacPorts itself and  
>> the ports tree.  If I understood you correctly, they'd then be  
>> running `port upgrade outdated` which still leaves MacPorts itself  
>> not updated.
>
> Oh -_- Right, having higher level scripts that call these commands  
> automatically made me forget how things worked... People are calling  
> sync ? I agree then that this isn't ideal, and your solution (sync  
> works just as selfupdate, with a --portfiles_only option) seems  
> adequate to me.
>
> If there isn't a consensus on this "merging", however, reminding  
> users that the "port" command hasn't been upgraded would be a  
> minimum (fix my end-of-sync sentence above to read "To upgrade the  
> 'port' command, please run 'port selfupdate'." :) ).
>
>> However, you do bring up an interesting idea I hadn't considered:  
>> why don't we have a command to do a all-things upgrade?  That is  
>> `selfupdate` + `upgrade outdated`?
>
> This has been discussed before (Ryan probably was the clearest on  
> why we do things this way, iirc). One reason I think was that "port  
> upgrade" warranted some caution, in particular as to which ports  
> would be in fact, upgraded, so that many users do
>
>> port selfupdate
>> port outdated
>> port upgrade outdated (if "port outdated"'s output isn't scary,  
>> else they upgrade only some ports)
>
> this would be the equivalent of other packaging system's  
> "confirmation before upgrading" dialogs (apt-get, aptitude ask  
> before upgrading installed software and list the changes that will  
> be made). This would be a bit more development, and I guess  
> discussion came to an end there.


I have my own little shell script that does (amongst other things)

sudo port -v selfupdate
sudo port outdated
#sudo port upgrade outdated
#sudo port uninstall -f inactive
echo All Done

The commented lines are because a few versions of Macports ago, if you  
tried
sudo port upgrade outdated
and "outdated" was nothing, ie nothing needed upgrading, then there  
was a very confusing error message.

But I've just tried it in 1.8.1 and although it could be slightly  
better it's not as bad as it once was.

iMac:~ $ sudo port upgrade outdated
Error: No ports matched the given expression

"There are no upgrades available in MacPorts for your installed ports."
is perhaps a clearer message for users in this case.



Mark


More information about the macports-dev mailing list