[pacman-dev] noconfirm trivial bug - prompt printed but unused/unnecessary
allan at archlinux.org
Wed May 20 08:24:54 EDT 2009
Brendan Hide wrote:
> Hi all
> I'm still getting my head around git and pacman-dev's workflow - I
> know its not that complicated, just need a bit of time.
> When using --noconfirm the prompt is presented (odd part) and the user
> (rightly) is not given an opportunity to confirm:
>> [ brendan at swift : 12:36:40 : ~/src/pacman ]
>> :) sudo pacman -Sc --noconfirm
>> Cache directory: /var/cache/pacman/pkg/
>> Do you want to remove outdated packages from cache?
>> [Y/n] <------
>> removing old packages from cache... done.
>> Database directory: /var/lib/pacman/
>> Do you want to remove unused repositories? [Y/n] <------
>> Database directory cleaned up
>> [ brendan at swift : 12:36:57 : ~/src/pacman ]
> Best fix I can think of is to just mention that we're using a default
> because the --noconfirm flag has been used. The alternative (which is
> less informative for the user) is to not present the prompt at all.
I'd be in favour of the less informative route. I.e.
sudo pacman -Sc --noconfirm
Cache directory: /var/cache/pacman/pkg/
removing old packages from cache... done.
Database directory: /var/lib/pacman/
Database directory cleaned up
Note the only long operation is the "removing old packages from
cache..." which notifies the user what is being done anyway. So I think
it best not to output those messages. And if you make the "r" in
"removing" a capital like every other message in that output at the same
time, that would be good.
More information about the pacman-dev