Tuesday, February 2, 2010

Re: remove and clean CDATA out of xml

> :%s/<!\[\[CDATA\[\(\%(\%(]]>\)\@!\_.\)\{-}\)]]>/\=substitute(submatch(1),'<[^>]*>', '', 'g')/g

I have a hard time understand the \(\%(\%(]]>\)\@!\_.\)\{-}\) part.
What does it do? What does \% mean? I do understand it will take
anything in CDATA brackets and run the substiture command over it.


thanks

--
You received this message from the "vim_use" maillist.
For more information, visit http://www.vim.org/maillist.php

No comments: