From 56425673fd424f2fd063f72ae02b5ab35b621b0f Mon Sep 17 00:00:00 2001 From: Michael Hanke Date: Wed, 26 Aug 2009 21:35:50 -0400 Subject: [PATCH] Acknowledge paragraphs in long descriptions. --- neurodebian/dde.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/neurodebian/dde.py b/neurodebian/dde.py index 0ebb0ee..826710f 100644 --- a/neurodebian/dde.py +++ b/neurodebian/dde.py @@ -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, -- 2.39.2