carolshubot icon indicating copy to clipboard operation
carolshubot copied to clipboard

Butts should have a \b around the regex

Open carols10cents opened this issue 10 years ago • 2 comments

otherwise sometimes it replaces parts of words if a word it picks is also a substring of another word

so if i say "i'm eating a sub in my submarine" and it picks sub, without word boundary in the regex, it would end up "i'm eating a butt in my buttmarine" which may or may not be what you intend...

carols10cents avatar Mar 19 '14 18:03 carols10cents

I've seen it cause issues and I wanted to fix it... until I read your example 

Justin Reese @justinxreese

On Wed, Mar 19, 2014 at 2:29 PM, Carol Nichols [email protected] wrote:

otherwise sometimes it replaces parts of words if a word it picks is also a substring of another word

so if i say "i'm eating a sub in my submarine" and it picks sub, without word boundary in the regex, it would end up "i'm eating a butt in my buttmarine" which may or may not be what you intend...

Reply to this email directly or view it on GitHub: https://github.com/carols10cents/carolshubot/issues/60

justinxreese avatar Mar 19 '14 18:03 justinxreese

Ha! This thread: :+1:

brennx0r avatar Mar 19 '14 18:03 brennx0r