$text =~ s!^\s*\*\s*(.+)$!<li>$1</li>!gm;
$text =~ s!<li>!<ul>\n<li>!s;
$text =~ s!(.*</li>)!$1\n</ul>!s;
$text =~ s!(?<=\s)\*(\S[^\*]+?\S)\*(?=\s)!<b>$1</b>
$text =~ s!(?<=\s)/(\S[^\*]+?\S)/(?=\s)!<i>$1</i>
$text =~ s^(?<!>)(\r\n|\n|\r)^<br />$1^gs;
All so that things like
la la la /but/ la la *then* la la
la la la but la la then la la
And I refuse to implement Markdown or anything like that for this. And because XML::Simple is too dumb to let me say "never parse the contents of tags named <text>".
edit: also, one of these days I might actually remember how to write zero-width negative look-behinds, so I don't have to keep looking it up. But not yet.