[config] more cleanup
authorSylvain Thénault <sylvain.thenault@logilab.fr>
Thu, 25 Mar 2010 20:46:22 +0100
changeset 5026 1f8238eaec9b
parent 5025 2826f5406201
child 5027 d688daf0a62c
[config] more cleanup
cwconfig.py
cwctl.py
--- a/cwconfig.py	Thu Mar 25 20:38:58 2010 +0100
+++ b/cwconfig.py	Thu Mar 25 20:46:22 2010 +0100
@@ -342,7 +342,9 @@
                            % directory)
                 continue
             for cube in os.listdir(directory):
-                if isdir(join(directory, cube)) and not cube == 'shared':
+                if cube in ('CVS', '.svn', 'shared', '.hg'):
+                    continue
+                if isdir(join(directory, cube)):
                     cubes.add(cube)
         return sorted(cubes)
 
@@ -906,7 +908,8 @@
                 if exists(sitefile) and not sitefile in self._site_loaded:
                     self._load_site_cubicweb(sitefile)
                     self._site_loaded.add(sitefile)
-                    self.warning('[3.5] site_erudi.py is deprecated, should be renamed to site_cubicweb.py')
+                    self.warning('[3.5] site_erudi.py is deprecated, should be '
+                                 'renamed to site_cubicweb.py')
 
     def _load_site_cubicweb(self, sitefile):
         # XXX extrapath argument to load_module_from_file only in lgc > 0.46
--- a/cwctl.py	Thu Mar 25 20:38:58 2010 +0100
+++ b/cwctl.py	Thu Mar 25 20:46:22 2010 +0100
@@ -285,8 +285,6 @@
         else:
             print 'Available cubes (%s):' % cubesdir
             for cube in cwcfg.available_cubes():
-                if cube in ('CVS', '.svn', 'shared', '.hg'):
-                    continue
                 try:
                     tinfo = cwcfg.cube_pkginfo(cube)
                     tversion = tinfo.version