In the manual page it also says that "This is equally to running apt-
mark auto for all installed packages." It is unclear from the wording if
it means all freshly installed packages (meaning here the packages no
version of which were installed before) or also packages that were
upgraded/downgraded or even all packages that were ordered for
installation in the command line and their dependencies.

Even if the auto-state is unchanged with --mark-auto when upgrading, it
might not be unchanged without --mark-auto, if the package is upgraded
and the package does not have a reserve dependency installed. (The
output does not show the difference, though, at least for apt 2.7.14) So
the usual rule is not that simple. I wonder in which case user would
want to have such a package marked as auto, though.

I have a script by which I want to downgrade packages matching current
software source settings, and I want to protect a package from being
marked manual without a reason when possibly downgrading the package and
possibly retaining the version of it. Currently I do the protection so
that I inspect the output for lines like "<pkg name> set to manually
installed." of the apt install command and run apt-mark auto for those
packages thereafter.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/2100937

Title:
  apt install --mark-auto does not retain auto mark

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/apt/+bug/2100937/+subscriptions


-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to