19 |
19 |
20 web = 'http://www.cubicweb.org/project/%%s' %% distname |
20 web = 'http://www.cubicweb.org/project/%%s' %% distname |
21 |
21 |
22 |
22 |
23 from os import listdir as _listdir |
23 from os import listdir as _listdir |
24 from os.path import join, isdir, exists, dirname |
24 from os.path import join, isdir, exists |
25 from glob import glob |
25 from glob import glob |
26 |
26 |
27 THIS_CUBE_DIR = join('share', 'cubicweb', 'cubes', modname) |
27 THIS_CUBE_DIR = join('share', 'cubicweb', 'cubes', modname) |
28 |
28 |
29 def listdir(dirpath): |
29 def listdir(dirpath): |
35 data_files = [ |
35 data_files = [ |
36 # common files |
36 # common files |
37 [THIS_CUBE_DIR, [fname for fname in glob('*.py') if fname != 'setup.py']], |
37 [THIS_CUBE_DIR, [fname for fname in glob('*.py') if fname != 'setup.py']], |
38 ] |
38 ] |
39 # check for possible extended cube layout |
39 # check for possible extended cube layout |
40 for dirname in ('entities', 'views', 'sobjects', 'hooks', 'schema', 'data', 'i18n', 'migration'): |
40 for dname in ('entities', 'views', 'sobjects', 'hooks', 'schema', 'data', 'i18n', 'migration'): |
41 if isdir(dirname): |
41 if isdir(dname): |
42 data_files.append([join(THIS_CUBE_DIR, dirname), listdir(dirname)]) |
42 data_files.append([join(THIS_CUBE_DIR, dname), listdir(dname)]) |
43 # Note: here, you'll need to add subdirectories if you want |
43 # Note: here, you'll need to add subdirectories if you want |
44 # them to be included in the debian package |
44 # them to be included in the debian package |
45 |
45 |
46 __depends_cubes__ = {} |
46 __depends_cubes__ = {} |
47 __depends__ = {'cubicweb': '>= 3.5.0'} |
47 __depends__ = {'cubicweb': '>= 3.5.0'} |