please say what -y (--assume-yes) is supposed to do
Hi!
There's some disagreement about the meaning of "apt-get -y <upgrade/...>".
The man page appears contrary to practice:
# -y, --yes, --assume-yes
# Automatic yes to prompts; assume "yes" as answer to all prompts and run
# non-interactively. If an undesirable situation, such as changing a
# held package, trying to install a unauthenticated package or removing
# an essential package occurs then apt-get will abort.
# Configuration Item: APT::Get::Assume-Yes.
Of those, "--assume-yes" describes the current behaviour accurately ("yes"
answer to most prompts, no switching to non-interactive), "run
non-interactively" is a lie as most of the upgrade/install/etc process
will require input, unless you set DEBIAN_FRONTEND=noninteractive.
That is, -y lets upgrade/install/autoremove proceed but you still get normal
debconf prompts, questions about conffile changes, etc.
However, in a recent upload of apt-listchanges (2.86) Robert Luberda, it's
new maintainer, went with the "non-interactively" meaning, making
apt-listchanges disobey its configured frontend and spew new changelog
entries to stdout without a pager.
I complained (#818712), and then Robert made two changes:
* obey DEBIAN_FRONTEND=noninteractive (a good fix, thanks!)
* require a weird option --ignore-apt-assume to have --assume-yes use
the configured apt-listchanges pager
It's the second part that I'm unhappy with.
Thus, could you guys please say what -y is supposed to mean?
As we'd want consistency, options I see are:
* "don't confirm the upgrade plan" -- ie, current behaviour of debconf,
conffile handling and apt-listchanges<2.86
* "noninteractive", in which case debconf and conffiles need to be changed
(probably by having apt set DEBIAN_FRONTEND=noninteractive)
Having one piece interpret it one way and others another is bad.
In particular in "apt-get upgrade" the confirmation is completely redundant
if you have apt-listchanges set to display changelogs as you would see the
list of packages to upgrade twice. At that point, ^C [1] does the same as
if you answered "n".
[1]. An useful tidbit: ^C with frontend=pager is a handier alternative for
apt-listchanges/confirm.
--
A tit a day keeps the vet away.
Reply to: