[TxMt] Re: Configuring HTML Tidy
Steve King
sking at arbor.net
Mon Sep 14 14:35:07 UTC 2009
Ibrahim Ezzy wrote:
> Not really. I manually indent where possible, but Tidy is required for
> tidying up someone else's files with hundreds of lines of code.
My solution to this sort of thing is to run Tidy, then follow up with a
regex replacement. In your case I'd do something like...
Find: <li>\n\s*(.*)\n\s*</li>
Replace: <li>$1</li>
This should pull out the newlines and extraneous spaces.
Kind of clumsy, but I suppose you could make a macro to do all this in
one keystroke if you need to do the same thing frequently.
--
Steve King
Sr. Software Engineer
Arbor Networks
+1 734 821 1461
www.arbornetworks.com <http://www.arbornetworks.com/>
More information about the textmate
mailing list