backport stable
authorSylvain Thénault <sylvain.thenault@logilab.fr>
Thu, 15 Apr 2010 19:02:41 +0200
changeset 44 ab6783fd3a15
parent 37 b03ebe2c494b (current diff)
parent 43 d596b292eee8 (diff)
child 45 57a92eae8941
backport stable
--- a/.hgtags	Wed Feb 10 16:14:25 2010 +0100
+++ b/.hgtags	Thu Apr 15 19:02:41 2010 +0200
@@ -2,3 +2,5 @@
 be80182ec9cf014ce2b7a31207bdcc02f106810b cubicweb-fresh-debian-version-0_3_1-1
 1f1e4a1efb58a407386af60fd5c6090c8e39af78 cubicweb-fresh-version-0.5.0
 23b964ed9f9649a92644af1b14238813edd955cd cubicweb-fresh-debian-version-0.5.0-1
+6f326f9908bd375725287b703693d68901b0d4e5 cubicweb-fresh-version-0.5.1
+4e43a847289138e0ffd33ea98e4b6817ff1e1e20 cubicweb-fresh-debian-version-0.5.1-1
--- a/MANIFEST.in	Wed Feb 10 16:14:25 2010 +0100
+++ b/MANIFEST.in	Thu Apr 15 19:02:41 2010 +0200
@@ -1,5 +1,5 @@
 include *.py
-
+recursive-include data *.xsl
 recursive-include views *.py
 recursive-include i18n *.pot *.po
 recursive-include migration *.sql *.py depends.map
--- a/__pkginfo__.py	Wed Feb 10 16:14:25 2010 +0100
+++ b/__pkginfo__.py	Thu Apr 15 19:02:41 2010 +0200
@@ -4,7 +4,7 @@
 modname = 'fresh'
 distname = 'cubicweb-fresh'
 
-numversion = (0, 5, 0)
+numversion = (0, 5, 1)
 version = '.'.join(str(num) for num in numversion)
 
 license = 'LGPL'
@@ -15,9 +15,8 @@
 author_email = 'contact@logilab.fr'
 
 short_desc = 'expense tracking application built on the CubicWeb framework'
-long_desc = '''This CubicWeb component provides an expense tracking application.
-
-CubicWeb is a semantic web application framework, see http://www.cubicweb.org
+long_desc = '''\
+This cube provides a full-featured expense tracking application.
 '''
 
 ftp = ''
@@ -48,21 +47,27 @@
 from os.path import join, isdir
 
 #from cubicweb.devtools.pkginfo import get_distutils_datafiles
-TEMPLATES_DIR = join('share', 'cubicweb', 'cubes')
-THIS_TEMPLATE_DIR = join(TEMPLATES_DIR, 'fresh')
+CUBES_DIR = join('share', 'cubicweb', 'cubes')
+THIS_CUBE_DIR = join(CUBES_DIR, modname)
 
 def listdir(dirpath):
     return [join(dirpath, fname) for fname in _listdir(dirpath)
             if fname[0] != '.' and not fname.endswith('.pyc')
-            and not fname.endswith('~')]
+            and not fname.endswith('~')
+            and not isdir(join(dirpath, fname))]
 
+from glob import glob
 try:
     data_files = [
-        [THIS_TEMPLATE_DIR, [fname for fname in glob('*.py') if fname != 'setup.py']],
-        [join(THIS_TEMPLATE_DIR, 'i18n'),  listdir('i18n')],
-        [join(THIS_TEMPLATE_DIR, 'views'), listdir('views')],
-        [join(THIS_TEMPLATE_DIR, 'migration'), listdir('migration')],
+        # common files
+        [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', 'wdoc'):
+        if isdir(dirname):
+            data_files.append([join(THIS_CUBE_DIR, dirname), listdir(dirname)])
+    # Note: here, you'll need to add subdirectories if you want
+    # them to be included in the debian package
 except OSError:
     # we are in an installed directory
     pass
--- a/debian/changelog	Wed Feb 10 16:14:25 2010 +0100
+++ b/debian/changelog	Thu Apr 15 19:02:41 2010 +0200
@@ -1,3 +1,9 @@
+cubicweb-fresh (0.5.1-1) unstable; urgency=low
+
+  * new upstream release
+
+ -- Sylvain Thénault <sylvain.thenault@logilab.fr>  Thu, 15 Apr 2010 16:30:03 +0200
+
 cubicweb-fresh (0.5.0-1) unstable; urgency=low
 
   * new upstream release
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/migration/0.5.1_Any.py	Thu Apr 15 19:02:41 2010 +0200
@@ -0,0 +1,1 @@
+sync_schema_props_perms('spent_for', syncprops=False)
--- a/schema.py	Wed Feb 10 16:14:25 2010 +0100
+++ b/schema.py	Thu Apr 15 19:02:41 2010 +0200
@@ -8,6 +8,6 @@
     cardinality = '?*'
     __permissions__ = {
         'read' : ('managers', 'users'),
-        'add': ('managers', RRQLExpression('S in_state ST, NOT ST name "accepted"')),
-        'delete': ('managers', RRQLExpression('S in_state ST, NOT ST name "accepted"')),
+        'add': ('managers', RRQLExpression('NOT (S in_state ST, ST name "accepted")')),
+        'delete': ('managers', RRQLExpression('NOT (S in_state ST, ST name "accepted")')),
         }