skeleton/__pkginfo__.py.tmpl
author Rémi Cardona <remi.cardona@logilab.fr>
Fri, 13 Nov 2015 14:29:48 +0100
changeset 10895 90c55e27aa87
parent 10214 88f60d4b9952
permissions -rw-r--r--
[data] Use correct syntax to unset CSS attributes (closes #8602446) 'default' is actually a recognized CSS cursor name (the regular pointer). Using this value doesn't revert to whatever cursor DOM elements have by default ('pointer' on links, 'text' on text, etc). The proper way to unset a CSS attribute on DOM elements is to set it to an empty string. http://stackoverflow.com/questions/2027935/how-to-remove-css-property-using-javascript
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
7003
6eeed1e9782c [skel] avoid pylint warning for newly generated cube
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents: 6828
diff changeset
     1
# pylint: disable=W0622
0
b97547f5f1fa Showtime !
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
diff changeset
     2
"""%(distname)s application packaging information"""
b97547f5f1fa Showtime !
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
diff changeset
     3
548
195a0065aaae missing quotes #102063
Aurelien Campeas <aurelien.campeas@logilab.fr>
parents: 538
diff changeset
     4
modname = '%(cubename)s'
0
b97547f5f1fa Showtime !
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
diff changeset
     5
distname = '%(distname)s'
b97547f5f1fa Showtime !
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
diff changeset
     6
b97547f5f1fa Showtime !
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
diff changeset
     7
numversion = (0, 1, 0)
b97547f5f1fa Showtime !
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
diff changeset
     8
version = '.'.join(str(num) for num in numversion)
b97547f5f1fa Showtime !
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
diff changeset
     9
5184
955ee1b24756 [c-c newcube] #1192: simpler cubicweb-ctl newcube, and more
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents: 5163
diff changeset
    10
license = '%(license)s'
458
99712f0d5472 fix syntax in skeleton's __pkginfo__.py
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents: 365
diff changeset
    11
author = '%(author)s'
99712f0d5472 fix syntax in skeleton's __pkginfo__.py
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents: 365
diff changeset
    12
author_email = '%(author-email)s'
6828
b022065b4376 [skeleton] nicer pkginfo organization
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents: 5536
diff changeset
    13
description = '%(shortdesc)s'
b022065b4376 [skeleton] nicer pkginfo organization
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents: 5536
diff changeset
    14
web = 'http://www.cubicweb.org/project/%%s' %% distname
0
b97547f5f1fa Showtime !
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
diff changeset
    15
10214
88f60d4b9952 [newcube] Make the generated code PEP-8 compliant
Christophe de Vienne <christophe@unlish.com>
parents: 8565
diff changeset
    16
__depends__ = %(dependencies)s
6828
b022065b4376 [skeleton] nicer pkginfo organization
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents: 5536
diff changeset
    17
__recommends__ = {}
0
b97547f5f1fa Showtime !
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
diff changeset
    18
8565
53c8cf9450b9 [skeleton] add pypi classifiers in __pkginfo__ and setup.py (closes #2502156)
Arthur Lutz <arthur.lutz@logilab.fr>
parents: 7758
diff changeset
    19
classifiers = [
53c8cf9450b9 [skeleton] add pypi classifiers in __pkginfo__ and setup.py (closes #2502156)
Arthur Lutz <arthur.lutz@logilab.fr>
parents: 7758
diff changeset
    20
    'Environment :: Web Environment',
53c8cf9450b9 [skeleton] add pypi classifiers in __pkginfo__ and setup.py (closes #2502156)
Arthur Lutz <arthur.lutz@logilab.fr>
parents: 7758
diff changeset
    21
    'Framework :: CubicWeb',
53c8cf9450b9 [skeleton] add pypi classifiers in __pkginfo__ and setup.py (closes #2502156)
Arthur Lutz <arthur.lutz@logilab.fr>
parents: 7758
diff changeset
    22
    'Programming Language :: Python',
53c8cf9450b9 [skeleton] add pypi classifiers in __pkginfo__ and setup.py (closes #2502156)
Arthur Lutz <arthur.lutz@logilab.fr>
parents: 7758
diff changeset
    23
    'Programming Language :: JavaScript',
53c8cf9450b9 [skeleton] add pypi classifiers in __pkginfo__ and setup.py (closes #2502156)
Arthur Lutz <arthur.lutz@logilab.fr>
parents: 7758
diff changeset
    24
    ]
2157
a4acf959d07e cleanup
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents: 1916
diff changeset
    25
a4acf959d07e cleanup
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents: 1916
diff changeset
    26
from os import listdir as _listdir
7758
1b8b83ff9f6b [skel] drop unused import
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents: 7003
diff changeset
    27
from os.path import join, isdir
2157
a4acf959d07e cleanup
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents: 1916
diff changeset
    28
from glob import glob
a4acf959d07e cleanup
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents: 1916
diff changeset
    29
a4acf959d07e cleanup
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents: 1916
diff changeset
    30
THIS_CUBE_DIR = join('share', 'cubicweb', 'cubes', modname)
0
b97547f5f1fa Showtime !
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
diff changeset
    31
10214
88f60d4b9952 [newcube] Make the generated code PEP-8 compliant
Christophe de Vienne <christophe@unlish.com>
parents: 8565
diff changeset
    32
0
b97547f5f1fa Showtime !
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
diff changeset
    33
def listdir(dirpath):
b97547f5f1fa Showtime !
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
diff changeset
    34
    return [join(dirpath, fname) for fname in _listdir(dirpath)
b97547f5f1fa Showtime !
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
diff changeset
    35
            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
    36
            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
    37
            and not isdir(join(dirpath, fname))]
0
b97547f5f1fa Showtime !
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents:
diff changeset
    38
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
    39
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
    40
    # 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
    41
    [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
    42
    ]
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
# check for possible extended cube layout
10214
88f60d4b9952 [newcube] Make the generated code PEP-8 compliant
Christophe de Vienne <christophe@unlish.com>
parents: 8565
diff changeset
    44
for dname in ('entities', 'views', 'sobjects', 'hooks', 'schema', 'data',
88f60d4b9952 [newcube] Make the generated code PEP-8 compliant
Christophe de Vienne <christophe@unlish.com>
parents: 8565
diff changeset
    45
              'wdoc', 'i18n', 'migration'):
4214
91887e8cf50c [skeleton] remove unused os.path.dirname import, use dname instead of dirname as an additional safetly belt
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents: 3492
diff changeset
    46
    if isdir(dname):
91887e8cf50c [skeleton] remove unused os.path.dirname import, use dname instead of dirname as an additional safetly belt
Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
parents: 3492
diff changeset
    47
        data_files.append([join(THIS_CUBE_DIR, dname), listdir(dname)])
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
    48
# 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
    49
# them to be included in the debian package