author | Sylvain Thénault <sylvain.thenault@logilab.fr> |
Mon, 19 Oct 2009 18:15:45 +0200 | |
changeset 3735 | 80fb4083c29b |
parent 3492 | bb520ce86afb |
child 4214 | 91887e8cf50c |
permissions | -rw-r--r-- |
0 | 1 |
# pylint: disable-msg=W0622 |
2 |
"""%(distname)s application packaging information""" |
|
3 |
||
548
195a0065aaae
missing quotes #102063
Aurelien Campeas <aurelien.campeas@logilab.fr>
parents:
538
diff
changeset
|
4 |
modname = '%(cubename)s' |
0 | 5 |
distname = '%(distname)s' |
6 |
||
7 |
numversion = (0, 1, 0) |
|
8 |
version = '.'.join(str(num) for num in numversion) |
|
9 |
||
10 |
license = 'LCL' |
|
365
5d8336b70aa7
make author information configurable
Sylvain Thenault <sylvain.thenault@logilab.fr>
parents:
319
diff
changeset
|
11 |
copyright = '''Copyright (c) %(year)s %(author)s. |
5d8336b70aa7
make author information configurable
Sylvain Thenault <sylvain.thenault@logilab.fr>
parents:
319
diff
changeset
|
12 |
%(author-web-site)s -- mailto:%(author-email)s''' |
0 | 13 |
|
458
99712f0d5472
fix syntax in skeleton's __pkginfo__.py
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
365
diff
changeset
|
14 |
author = '%(author)s' |
99712f0d5472
fix syntax in skeleton's __pkginfo__.py
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
365
diff
changeset
|
15 |
author_email = '%(author-email)s' |
0 | 16 |
|
17 |
short_desc = '%(shortdesc)s' |
|
18 |
long_desc = '''%(longdesc)s''' |
|
19 |
||
319
00ada106b138
fix skeleton __pkginfo__ template
Nicolas Chauvat <nicolas.chauvat@logilab.fr>
parents:
232
diff
changeset
|
20 |
web = 'http://www.cubicweb.org/project/%%s' %% distname |
0 | 21 |
|
2157 | 22 |
|
23 |
from os import listdir as _listdir |
|
24 |
from os.path import join, isdir, exists, dirname |
|
25 |
from glob import glob |
|
26 |
||
27 |
THIS_CUBE_DIR = join('share', 'cubicweb', 'cubes', modname) |
|
0 | 28 |
|
29 |
def listdir(dirpath): |
|
30 |
return [join(dirpath, fname) for fname in _listdir(dirpath) |
|
31 |
if fname[0] != '.' and not fname.endswith('.pyc') |
|
1438
21b8f3961e6f
[distutils] don't consider directories as data files
Julien Jehannet <julien.jehannet@logilab.fr>
parents:
548
diff
changeset
|
32 |
and not fname.endswith('~') |
1916
5c94f776e4f6
[skeleton] fix SyntaxError in __pkginfo__.py (looks like a copy/paste error from vim)
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
1438
diff
changeset
|
33 |
and not isdir(join(dirpath, fname))] |
0 | 34 |
|
2367
6ba269240f3b
[skeleton] the new implementation of data_files will never raise a OSError
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
2157
diff
changeset
|
35 |
data_files = [ |
6ba269240f3b
[skeleton] the new implementation of data_files will never raise a OSError
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
2157
diff
changeset
|
36 |
# common files |
6ba269240f3b
[skeleton] the new implementation of data_files will never raise a OSError
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
2157
diff
changeset
|
37 |
[THIS_CUBE_DIR, [fname for fname in glob('*.py') if fname != 'setup.py']], |
6ba269240f3b
[skeleton] the new implementation of data_files will never raise a OSError
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
2157
diff
changeset
|
38 |
] |
6ba269240f3b
[skeleton] the new implementation of data_files will never raise a OSError
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
2157
diff
changeset
|
39 |
# check for possible extended cube layout |
6ba269240f3b
[skeleton] the new implementation of data_files will never raise a OSError
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
2157
diff
changeset
|
40 |
for dirname in ('entities', 'views', 'sobjects', 'hooks', 'schema', 'data', 'i18n', 'migration'): |
6ba269240f3b
[skeleton] the new implementation of data_files will never raise a OSError
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
2157
diff
changeset
|
41 |
if isdir(dirname): |
6ba269240f3b
[skeleton] the new implementation of data_files will never raise a OSError
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
2157
diff
changeset
|
42 |
data_files.append([join(THIS_CUBE_DIR, dirname), listdir(dirname)]) |
6ba269240f3b
[skeleton] the new implementation of data_files will never raise a OSError
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
2157
diff
changeset
|
43 |
# Note: here, you'll need to add subdirectories if you want |
6ba269240f3b
[skeleton] the new implementation of data_files will never raise a OSError
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
2157
diff
changeset
|
44 |
# them to be included in the debian package |
0 | 45 |
|
3492 | 46 |
__depends_cubes__ = {} |
47 |
__depends__ = {'cubicweb': '>= 3.5.0'} |
|
0 | 48 |
__use__ = (%(dependancies)s) |
139 | 49 |
__recommend__ = () |
0 | 50 |