[yum-cvs] docs/yum.conf.5 yum/__init__.py

Seth Vidal skvidal at linux.duke.edu
Wed Sep 19 03:17:18 UTC 2007


 docs/yum.conf.5 |    4 ++++
 yum/__init__.py |   10 +++-------
 2 files changed, 7 insertions(+), 7 deletions(-)

New commits:
commit 8263c291bc7276cea2d61690c623129b869971f5
Author: Seth Vidal <skvidal at fedoraproject.org>
Date:   Tue Sep 18 23:11:22 2007 -0400

    add debug output to costExclude
    add cost man page entry

diff --git a/docs/yum.conf.5 b/docs/yum.conf.5
index 5f00b38..46fd092 100644
--- a/docs/yum.conf.5
+++ b/docs/yum.conf.5
@@ -384,6 +384,10 @@ If this is unset it inherits it from the global setting
 password for this proxy.
 If this is unset it inherits it from the global setting
 
+.IP \fBcost \fR
+relative cost of accessing this repository. Useful for weighing one repo's packages
+as greater/less than any other. defaults to 1000
+
 .SH "URL INCLUDE SYNTAX"
 .LP
 The inclusion of external configuration files is supported for /etc/yum/yum.conf
diff --git a/yum/__init__.py b/yum/__init__.py
index fc1d483..eeeb51e 100644
--- a/yum/__init__.py
+++ b/yum/__init__.py
@@ -636,15 +636,11 @@ class YumBase(depsolve.Depsolve):
             #print '%s : %s : %s' % (pkgs[0], pkgs[0].repo, pkgs[0].repo.cost)
             for pkg in pkgs[1:]:
                 if pkg.repo.cost > lowcost:
+                    msg = 'excluding for cost: %s from %s' % (pkg, pkg.repo.id)
+                    self.verbose_logger.log(logginglevels.DEBUG_3, msg)
                     pkg.repo.sack.delPackage(pkg)
             
-        # for each pkg in all pkgs - if there are more than one matching a single
-        # nevra then sort by repo.cost and trim out the ones with the higher
-        # repo.cost
-        # if all the repo.costs are the same then leave them all alone
-        
-        pass
-        
+
     def excludePackages(self, repo=None):
         """removes packages from packageSacks based on global exclude lists,
            command line excludes and per-repository excludes, takes optional 



More information about the Yum-cvs-commits mailing list