View Single Post
Old 11-28-2014, 06:29 PM   #2
cyttorak
Member
cyttorak began at the beginning.
 
Posts: 18
Karma: 10
Join Date: Nov 2014
Device: Kobo Mini
Question

Finally I do it work with:

Code:
	def parse_feeds (self):
		r = re.compile(u'^(\d+)(er\.?|o\.?|a\.|º|ª) (.*ACTA.*FE[MN]I[MN]ISMO.*)$', re.IGNORECASE|re.UNICODE)
		feeds = BasicNewsRecipe.parse_feeds(self)
		for f in feeds:
			for a,c in enumerate(f.articles):
				c.title=r.sub('\\1ª Acta Ganemos Feminismos',c.title)
		return feeds
is it a elegant solution? or is there a better way?
cyttorak is offline   Reply With Quote