[skeleton] remove unused os.path.dirname import, use dname instead of dirname as an additional safetly belt stable
authorAdrien Di Mascio <Adrien.DiMascio@logilab.fr>
Fri, 08 Jan 2010 11:45:37 +0100
branchstable
changeset 4214 91887e8cf50c
parent 4213 d4eeaf0393e2
child 4215 9fbc39453012
[skeleton] remove unused os.path.dirname import, use dname instead of dirname as an additional safetly belt
skeleton/__pkginfo__.py.tmpl
--- a/skeleton/__pkginfo__.py.tmpl	Thu Jan 07 17:41:50 2010 +0100
+++ b/skeleton/__pkginfo__.py.tmpl	Fri Jan 08 11:45:37 2010 +0100
@@ -21,7 +21,7 @@
 
 
 from os import listdir as _listdir
-from os.path import join, isdir, exists, dirname
+from os.path import join, isdir, exists
 from glob import glob
 
 THIS_CUBE_DIR = join('share', 'cubicweb', 'cubes', modname)
@@ -37,9 +37,9 @@
     [THIS_CUBE_DIR, [fname for fname in glob('*.py') if fname != 'setup.py']],
     ]
 # check for possible extended cube layout
-for dirname in ('entities', 'views', 'sobjects', 'hooks', 'schema', 'data', 'i18n', 'migration'):
-    if isdir(dirname):
-        data_files.append([join(THIS_CUBE_DIR, dirname), listdir(dirname)])
+for dname in ('entities', 'views', 'sobjects', 'hooks', 'schema', 'data', 'i18n', 'migration'):
+    if isdir(dname):
+        data_files.append([join(THIS_CUBE_DIR, dname), listdir(dname)])
 # Note: here, you'll need to add subdirectories if you want
 # them to be included in the debian package