I love tidy. I need tidy. What I really really want is a simple wrapper around tidy that will let me use it through Python.
It's not that the current set of wrappers are bad, it's just that they didn't meet my target requirements. What are my target requirements?
xhtml = pytidy.fix("just same <b>malformed HTML<br/> stuff")
That's it, just a single fucntion that takes in poor markup and then returns well-formed XHTML as output.
Download pyTidy, a simple Python wrapper of TidyLib that has just the minimal interface described above.
Type 'make' to build. This will build two files:
_pytidy.dll on Windows) and
Copy both of these files into your project, or the right location in your Python libraries.
Version 0.1 - Initial Release. Currently untested on Windows.
Yes, I would like to automate this whole process using distutils, but that will have to wait for a later release.