Comment on How to block posts about Elon Musk (or other custom string) on computer
madsen@lemmy.world 11 months agoYou can use the regex: /\\bx\\b/i
It’ll catch ‘x’ surrounded by word boundaries (stuff like spaces, dashes/hyphens, commas, etc.) but not ‘x’ with other letters on either side, so it won’t match e.g. “sax” or “boxer”, but it’ll match “x.com” and “Elon’s X” and stuff. It’s probably not perfect though, so use with caution.
TDCN@feddit.dk 11 months ago
It’s sadly not perfect as @Mananasi@feddit.nl also states, and since I like maths related stuff too and science it’ll likely filter out too much stuff. But I appreciate your efforts. An ai algorithm or a community created blacklist is probably the only solution.
madsen@lemmy.world 11 months ago
Yeah, good points. I did note, though, that it probably wasn’t perfect. I kinda figured it would probably catch other stuff too but I couldn’t think of anything specific at the time.