summaryrefslogtreecommitdiff
path: root/apt-private/private-upgrade.cc
diff options
context:
space:
mode:
authorMichael Vogt <mvo@debian.org>2014-01-24 20:33:02 +0100
committerMichael Vogt <mvo@debian.org>2014-01-24 20:33:02 +0100
commit59e81cec3e2277e367f14f113168421909c42035 (patch)
treecfc300c504eb8b8a3ae46820549c322e12ff884b /apt-private/private-upgrade.cc
parent6d73fe5be080e66a4f6ff2b250ed1957ae7ac063 (diff)
add "apt full-upgrade" and tweak "apt upgrade"
There is a new "apt full-upgrade" that performs a apt-get dist-upgrade. "apt dist-upgrade" is still supported as a alias. The "apt upgrade" code is changed so that it mirrors the behavior of "apt-get upgrade --with-new-pkgs" and also honors "apt uprade --no-new-pkgs".
Diffstat (limited to 'apt-private/private-upgrade.cc')
-rw-r--r--apt-private/private-upgrade.cc9
1 files changed, 9 insertions, 0 deletions
diff --git a/apt-private/private-upgrade.cc b/apt-private/private-upgrade.cc
index e76b5d7fc..a97e6d25b 100644
--- a/apt-private/private-upgrade.cc
+++ b/apt-private/private-upgrade.cc
@@ -1,3 +1,4 @@
+
// Includes /*{{{*/
#include <apt-pkg/algorithms.h>
#include <apt-pkg/upgrade.h>
@@ -39,6 +40,14 @@ bool DoDistUpgrade(CommandLine &CmdL)
return UpgradeHelper(CmdL, 0);
}
/*}}}*/
+bool DoUpgrade(CommandLine &CmdL) /*{{{*/
+{
+ if (_config->FindB("APT::Get::Upgrade-Allow-New", false) == true)
+ return DoUpgradeWithAllowNewPackages(CmdL);
+ else
+ return DoUpgradeNoNewPackages(CmdL);
+}
+ /*}}}*/
// DoUpgradeNoNewPackages - Upgrade all packages /*{{{*/
// ---------------------------------------------------------------------
/* Upgrade all packages without installing new packages or erasing old