trac2rst /

Filename Size Date modified Message
src
78 B
85 B
135 B
414 B
431 B
309 B
39 B
1.7 KB
3.4 KB
206 B
1.3 KB
1.0 KB

trac2rst

I use trac2rst to help me in the task to pass documentacion from trac to sphinx. I usally copy the trac wiki page to a temporaly file, run the script, copy the output to the new rest file and do manual changes.

Features

The idea is use the tool to do the more tedious work (I mean transforming lists, links and inliners). You must review and fix the result later.

It only processes:
  • Headers (sections at 4 levels)
  • Lists (bullets and numbered)
  • Trac links.
  • A subject of trac and rest inliners
It does NOT support (a lot):
  • Trac macros
  • Trac processors
  • Links between wiki pages
  • Rest definition lists, etc
  • Preformatting
  • Images
  • Tables
  • Footnotes
  • Anchors
  • Citations
  • Comments
  • A lot more ...

Usage example

Type trac2rst --help

You can view a simple wiki transfomation (used for manual test):

$ bin/trac2rst -i src/trac2rst/tests/wikitext.txt -u https://trac.yaco.es/project/  -o /tmp/test.rst && rst2html /tmp/test.rst /tmp/test.html && firefox /tmp/test.html

Disclaimer

This is a quick and dirty tool. It does not use reST or wiki processor. The work is done using regular expressions.

License

trac2rst is offered under the MIT license.

Authors

trac2rst is made available by Yaco Sistemas

Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.