]> git.donarmstrong.com Git - neurodebian.git/commitdiff
Acknowledge paragraphs in long descriptions.
authorMichael Hanke <michael@pymvpa.org>
Thu, 27 Aug 2009 01:35:50 +0000 (21:35 -0400)
committerMichael Hanke <michael@pymvpa.org>
Thu, 27 Aug 2009 01:35:50 +0000 (21:35 -0400)
neurodebian/dde.py

index 0ebb0eefef9a00bfe13c30c2a7c9e945176e3a00..826710f972edd93ea6db6949df816f8c614b897b 100644 (file)
@@ -441,10 +441,13 @@ def generate_pkgpage(pkg, cfg, db, template, addenum_dir):
     title = '%s\n %s\n%s' % (underline, title, underline)
 
     # preprocess long description
-    print 'rendering', pkg
     ld = db['main']['long_description']
-    print 'AAAAA', repr(ld), type(ld)
-    ld = u' '.join([l.lstrip(' .') for l in ld.split('\n')])
+    ld = ld.split('\n')
+    for i, l in enumerate(ld):
+        if l == ' .':
+            ld[i] = '#NEWLINEMARKER#'
+    ld = u' '.join([l.lstrip() for l in ld])
+    ld = ld.replace('#NEWLINEMARKER# ', '\n\n')
 
     page = template.render(pkg=pkg,
                            title=title,