[yum-commits] Branch 'yum-3_2_X' - 6 commits - cli.py output.py yum/config.py yum/__init__.py yummain.py
James Antill
james at osuosl.org
Mon Mar 14 15:42:43 UTC 2011
cli.py | 5 +++++
output.py | 2 +-
yum/__init__.py | 10 ++++++++--
yum/config.py | 20 +++++++++++++++++---
yummain.py | 4 ++--
5 files changed, 33 insertions(+), 8 deletions(-)
New commits:
commit 32c0ea6d341909b487883485f031f6d2e218bd50
Merge: 5cd470c... 4157857...
Author: James Antill <james at and.org>
Date: Mon Mar 14 11:42:27 2011 -0400
Merge branch 'yum-3_2_X' of ssh://yum.baseurl.org/srv/projects/yum/git/yum into yum-3_2_X
* 'yum-3_2_X' of ssh://yum.baseurl.org/srv/projects/yum/git/yum:
add 'available' to yum help list output thx to Robert Day for pointing this out.
commit 5cd470cde22f2058f004db6668d41dda1b27c2c0
Author: James Antill <james at and.org>
Date: Mon Mar 14 11:23:15 2011 -0400
Add saved_tx to default_addons, for history info output.
diff --git a/output.py b/output.py
index 08fe0e3..1613c29 100755
--- a/output.py
+++ b/output.py
@@ -1741,7 +1741,7 @@ to exit.
addon_info = self.history.return_addon_data(old.tid)
# for the ones we create by default - don't display them as there
- default_addons = set(['config-main', 'config-repos'])
+ default_addons = set(['config-main', 'config-repos', 'saved_tx'])
non_default = set(addon_info).difference(default_addons)
if len(non_default) > 0:
print _("Additional non-default information stored: %d"
commit 1903fb47f37be15089896ff3783d975f9bc318d2
Author: James Antill <james at and.org>
Date: Fri Mar 11 11:02:51 2011 -0500
Commit warn_checks change.
diff --git a/yummain.py b/yummain.py
index b4d90e4..d0b8251 100755
--- a/yummain.py
+++ b/yummain.py
@@ -191,7 +191,7 @@ def main(args):
logger.critical(prefix, msg.replace('\n', '\n' + prefix2nd))
if not base.conf.skip_broken:
verbose_logger.info(_(" You could try using --skip-broken to work around the problem"))
- warn_checks()
+ rpmdb_warn_checks()
if unlock(): return 200
return 1
elif result == 2:
@@ -223,7 +223,7 @@ def main(args):
(result, resultmsgs) = return_code
for msg in resultmsgs:
logger.critical("%s", msg)
- warn_checks()
+ rpmdb_warn_checks()
return_code = result
if base._ts_save_file:
verbose_logger.info(_("Your transaction was saved, rerun it with: yum load-transaction %s") % base._ts_save_file)
commit a59998942224a36f62ba3a4247bd8f2dc92eceab
Author: James Antill <james at and.org>
Date: Thu Mar 10 13:43:35 2011 -0500
Don't update-install same version diff. arch local pkgs.
diff --git a/yum/__init__.py b/yum/__init__.py
index 5c44245..36fc203 100644
--- a/yum/__init__.py
+++ b/yum/__init__.py
@@ -3956,11 +3956,17 @@ class YumBase(depsolve.Depsolve):
if (po.arch != installed_pkg.arch and
(isMultiLibArch(po.arch) or
isMultiLibArch(installed_pkg.arch))):
- installpkgs.append(po)
+ if updateonly:
+ self.logger.warning(_('Package %s.%s not installed, cannot update it. Run yum install to install it instead.'), po.name, po.arch)
+ else:
+ installpkgs.append(po)
else:
donothingpkgs.append(po)
elif self.allowedMultipleInstalls(po):
- installpkgs.append(po)
+ if updateonly:
+ self.logger.warning(_('Package %s.%s not installed, cannot update it. Run yum install to install it instead.'), po.name, po.arch)
+ else:
+ installpkgs.append(po)
else:
donothingpkgs.append(po)
commit f1c339d5eb04a5fee399b2c3c52103cb025d521c
Author: James Antill <james at and.org>
Date: Thu Mar 10 13:29:37 2011 -0500
Fix RHEL-5 yum-utils/yumdownloader, when using 3.2.29+.
diff --git a/cli.py b/cli.py
index a4c7c79..576126d 100644
--- a/cli.py
+++ b/cli.py
@@ -45,6 +45,11 @@ import yumcommands
from yum.i18n import to_unicode, to_utf8
+# This is for yum-utils/yumdownloader in RHEL-5, where it isn't importing this
+# directly but did do "from cli import *", and we did have this in 3.2.22. I
+# just _love_ how python re-exports these by default.
+from yum.packages import parsePackages
+
def sigquit(signum, frame):
""" SIGQUIT handler for the yum cli. """
print >> sys.stderr, "Quit signal sent - exiting immediately"
commit 3dc88cfce500e2031597a5f8399cfb911bbef4b0
Author: James Antill <james at and.org>
Date: Thu Mar 10 12:47:31 2011 -0500
Deal with yumvar interpreted values, like baseurl.
diff --git a/yum/config.py b/yum/config.py
index 9c2db93..8c966f8 100644
--- a/yum/config.py
+++ b/yum/config.py
@@ -1051,10 +1051,24 @@ def writeRawRepoFile(repo,only=None):
# Updated the ConfigParser with the changed values
cfgOptions = repo.cfg.options(repo.id)
for name,value in repo.iteritems():
+ if value is None: # Proxy
+ continue
+
+ if only is not None and name not in only:
+ continue
+
option = repo.optionobj(name)
- if option.default != value or name in cfgOptions :
- if only == None or name in only:
- ini[section_id][name] = option.tostring(value)
+ ovalue = option.tostring(value)
+ # If the value is the same, but just interpreted ... when we don't want
+ # to keep the interpreted values.
+ if (name in ini[section_id] and
+ ovalue == varReplace(ini[section_id][name], yumvar)):
+ ovalue = ini[section_id][name]
+
+ if name not in cfgOptions and option.default == value:
+ continue
+
+ ini[section_id][name] = ovalue
fp =file(repo.repofile,"w")
fp.write(str(ini))
fp.close()
More information about the Yum-commits
mailing list