[yum-cvs] yum/yum config.py,1.81,1.82

Jeremy Katz katzj at login.linux.duke.edu
Thu Dec 8 23:19:43 UTC 2005


Update of /home/groups/yum/cvs/yum/yum
In directory login:/tmp/cvs-serv17679/yum

Modified Files:
	config.py 
Log Message:
fix for gratutious config API breakage


Index: config.py
===================================================================
RCS file: /home/groups/yum/cvs/yum/yum/config.py,v
retrieving revision 1.81
retrieving revision 1.82
diff -u -r1.81 -r1.82
--- config.py	3 Dec 2005 07:15:10 -0000	1.81
+++ config.py	8 Dec 2005 23:19:41 -0000	1.82
@@ -356,6 +356,11 @@
         for name in self.iterkeys():
             yield (name, getattr(self, name))
 
+    def getConfigOption(self, option, default=None):
+        if hasattr(self, option):
+            return getattr(self, option)
+        return default
+
 class EarlyConf(BaseConfig):
 
     distroverpkg = Option('fedora-release')
@@ -519,7 +524,6 @@
         return default
     return option.parse(val)
 
-
 def _getEnvVar():
     '''Return variable replacements from the environment variables YUM0 to YUM9
 




More information about the Yum-cvs-commits mailing list