projects
/
webmin.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5f67cd3
)
Use safe-upgrade with aptitude
author
Jamie Cameron
<jcameron@webmin.com>
Tue, 20 Oct 2009 18:53:21 +0000
(11:53 -0700)
committer
Jamie Cameron
<jcameron@webmin.com>
Tue, 20 Oct 2009 18:53:21 +0000
(11:53 -0700)
software/apt_upgrade.cgi
patch
|
blob
|
history
diff --git
a/software/apt_upgrade.cgi
b/software/apt_upgrade.cgi
index
bf6d9a4
..
ba4edb1
100755
(executable)
--- a/
software/apt_upgrade.cgi
+++ b/
software/apt_upgrade.cgi
@@
-30,7
+30,8
@@
if ($in{'update'}) {
if ($in{'mode'}) {
$opts = $in{'sim'} ? "-s -y -f" : "-y -f";
- $cmd = $in{'mode'} == 2 ? "dist-upgrade" : "upgrade";
+ $cmd = $in{'mode'} == 2 ? "dist-upgrade" :
+ $apt_get_command =~ /aptitude/ ? "safe-upgrade" : "upgrade";
print "<b>",&text($in{'sim'} ? 'apt_upgradedescsim' : 'apt_upgradedesc', "<tt>$apt_get_command $opts $cmd</tt>"),"</b><p>\n";
print "<pre>";
&additional_log("exec", undef, "$apt_get_command $opts $cmd");