Blog titles not parsing
Gordon Hodgson
feeds at greenfeed.org.uk
Wed Oct 29 04:21:36 EST 2008
Sorry,
I couldn't get it to work, I kept indent and syntax errors, but then I
don't really know python.
Gordon
On 22 Oct 2008, at 20:41, Sam Ruby wrote:
> feeds at greenfeed.org.uk wrote:
>> Hi Sam,
>> I've got Venus up and running properly now, so I'm glad.
>> One last thing (I hope) the subscription list on the left is not
>> alphabetically sorted for blogs where the title has been pulled
>> from the RSS, only where it has been added manually. Are you able
>> to fix this?
>
> It can be done, but I don't have time to test it properly at the
> moment. Can you find the block containing the word "sort" in planet/
> shell/tmpl.py, and replace it with the following:
>
> # apply rules to convert feed parser output to htmltmpl input
> output = {'Channels': [], 'Items': []}
> output.update(tmpl_mapper(data.feed, Base))
> sources = []
> for feed in data.feed.get('sources',[]):
> source = tmpl_mapper(feed, Base)
> sources.append([source.get('name'), source])
> sources.sort()
> output['Channels'] = [source for name,source in sources]
> for entry in data.entries:
> output['Items'].append(tmpl_mapper(entry, Items))
>
> If it works for you, I'll commit it.
>
>> Cheers,
>> Gordon
>
> - Sam Ruby
>
More information about the devel
mailing list