File size: 231 Bytes
c8a32e7
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
import re


def replace_bullets(text):
    # Replace bullet characters with a -
    bullet_pattern = r"(^|[\n ])[•●○■▪▫–—]( )"
    replaced_string = re.sub(bullet_pattern, r"\1-\2", text)
    return replaced_string