[TxMt] Newbie Customization of Tidy

Allan Odgaard throw-away-1 at macromates.com
Thu Nov 9 03:37:53 UTC 2006


On 9. Nov 2006, at 02:56, hcabbos wrote:

> Can anyone point me to instructions on how to modify HTML Tidy's  
> formatting of documents. There's a bunch of stuff that happens that  
> I don't care for...stuff that running HTML Tidy in BBEdit doesn't  
> do. I'd love Dreamweaver's method of formatting within TextMate--at  
> least for HTML files. What's nice about BBEdit is that it allows  
> you to point to Dreamweaver's SourceProfile.txt file as a custom  
> profile for source formatting.

Select Bundles → Bundle Editor → Show Bundle Editor. Then unfold  
HTML and locate the Tidy command.

Currently these are the options used:

     "${TM_TIDY:-tidy}" -f /dev/null -iq -utf8 \
         -wrap 0 --tab-size $TM_TAB_SIZE --indent-spaces $TM_TAB_SIZE \
         ${TM_SELECTED_TEXT:+--show-body-only yes} \
         ${TM_XHTML:+-asxhtml} \
         --doctype strict \
         --enclose-text yes \
         --tidy-mark no

We have debated a little about doing a dialog for the options (via  
tm_dialog) but I think none of us (who debated this) use tidy, and  
most of us think we should just ensure it has good defaults.

Please let us know which options you think should be changed.





More information about the textmate mailing list