well, if you do, a gift:
(*
This script properly formats xml (really)
*)
tell application "BBEdit 6.1"
activate
format mode hierarchical
replace "([^>])
([ ]+)<" using "\\1<" searching in text 1 of text window 1 options
{search mode:grep, starting at top:true, wrap around:false}
replace ">\\r([\\t]+)(\\w)([^<]+)</" using ">\\2\\3</" searching in text
1 of text window 1 options {search mode:grep, starting at top:true, wrap
around:false}
replace ">\\r([\\s]+)(#+)</" using ">\\2</" searching in text 1 of text
window 1 options {search mode:grep, starting at top:true, wrap around:false}
replace "}}} -->
<" using "}}} -->
<" searching in text 1 of text window 1 options {search mode:literal,
starting at top:true, wrap around:false}
end tell
that applescript formats xml perfectly :) it was a pain in the ass to
construct :) enjoy...
_a
--
alex black, ceo
en...@tu...
the turing studio, inc.
http://www.turingstudio.com
vox+510.666.0074
fax+510.666.0093
|