Jaap Karssenberg escribió:
> In fact the python port already has a fairly decent parser for the zim
> wiki format that can be used as a base for this kind of work. Your
> code will at least be very useful a example on how to format the trac
> output (btw. from your subject line I assume trac uses the mediawiki
> format - is that correct ?).
I think trac wiki format is similar to mediawiki, but there are
> I will add this piece of code to the python dev tree, so it can be
> used as a basis later.
The code is based in observation, I didn't try to read the full
specification of trac. If you have a parser, the whole approach is
doomed. I don't know if it's a good idea to add this code to the tree.
>> The following python code is a hack, and it might fail on some syntax.
>> I took a choice regarding links with categories: I decided to flatten
>> zim links like [[:Software:note taking:zim|zim]] to wiki entries like
>> [Software_note_taking_zim zim].
> I don't know what characters are allowed in page names in trac - is
> there another character that can be used to make the hierarchy more
> obvious ? Or maybe flatten using a double "_" ?
You're right, a double "_" is better. For mediawiki, it would be
important to take care of "mediawiki categories" too. Trac has a plugin
implemeting "tags", but it's not a standard plugin.
In a few months I'll have time to read and think about zim. I'm looking
forward to reading the python port.
Mailing list: https://launchpad.net/~zim-wiki
Post to : email@example.com
Unsubscribe : https://launchpad.net/~zim-wiki
More help : https://help.launchpad.net/ListHelp