Revision: 5492 Author: jayvdb Date: 2008-06-02 02:32:06 +0000 (Mon, 02 Jun 2008)
Log Message: ----------- Convert djvutxt new line character to wiki syntax
Modified Paths: -------------- trunk/pywikipedia/djvutext.py
Modified: trunk/pywikipedia/djvutext.py =================================================================== --- trunk/pywikipedia/djvutext.py 2008-06-01 14:10:36 UTC (rev 5491) +++ trunk/pywikipedia/djvutext.py 2008-06-02 02:32:06 UTC (rev 5492) @@ -121,6 +121,10 @@ djvutxt = wikipedia.translate(wikipedia.getSite(), self.blank) text = '<noinclude>{{PageQuality|1|%s}}<div class="pagetext">%s</noinclude>%s<noinclude><references/></div></noinclude>' % (self.username,"\n\n\n",djvutxt)
+ # convert to wikisyntax + # this adds a second line feed, which makes a new paragraph + text = text.replace('', "\n") + # only save if something was changed if (not exists and text) or text != page.get(): # Show the title of the page we're working on.
pywikipedia-l@lists.wikimedia.org