Jorge Vargas wrote:
> Dear python users, do you know of a tool like this that is written in python?
> 
> http://code.google.com/p/css-redundancy-checker/
> 
> in case you where wondering I just don't want to have the ruby
> dependency on my python proyects.

This comes to mind:

http://code.google.com/p/cssutils/

Not sure if it does what you want, though. If not, it should be quite trivial
to implement what you ask using this:

http://codespeak.net/lxml/cssselect.html

Algorithm: for each CSS selector in the stylesheet, check if it matches an
element in the HTML tree. If not, remove it.

Stefan
--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to