public static string HTMLListToWiki(string text, string bullet)
{
text = text.Replace("\r\n\r\n", "\r\n");
text = Regex.Replace(text, "<br ?/?>", "", RegexOptions.IgnoreCase);
text = Regex.Replace(text, "</?(ol|ul|li)>", "", RegexOptions.IgnoreCase);
text = Regex.Replace(text, "^</?(ol|ul|li)>\r\n", "", RegexOptions.Multiline | RegexOptions.IgnoreCase);
text = Regex.Replace(text, @"^(\:|\*|#|\(? ?\d{1,3}\b ?\)|\d{1,3}\b\.?)", "", RegexOptions.Multiline);
// add bullet to start of each line, but not empty lines or lines with just whitespace
return WholeLine.Replace(text, m => bullet + " " + m.Groups[1].Value.TrimStart());
}